Appearance
Let visitors reopen the banner
Consent has to be as easy to change as it was to give. The floating icon in the corner does that job by default, but a link in your footer is what most visitors look for — and several US state laws expect the opt-out to be reachable from every page, which an icon alone makes an argument about rather than a fact. If that is why you are here, US state laws has the wording those statutes expect, which is not ours to paraphrase.
There are two ways to do it. They do the same thing; pick whichever fits your site.
The attribute
html
<a href="#" data-cookiewave="show-preferences">Cookie preferences</a>Any element works — a link, a button, something inside your own menu component. Put the attribute on whatever the visitor clicks and nothing else is needed: no script, no return false, no waiting for the banner to load first.
This is the one to use if your site sends a Content-Security-Policy header. The other form below is an inline script, which a policy without unsafe-inline blocks — silently, and only in production, which is a poor place to find out.
It also survives your page being re-rendered. CookieWave listens on the document rather than on the element, so a footer that React or Vue redraws keeps working without rebinding anything.
The JavaScript call
html
<a href="#" onclick="window.CookieWave.showPreferences(); return false;">
Cookie preferences
</a>window.CookieWave.showPreferences() is available from your own code too — a menu item, a settings screen, anything you already have. The return false is what stops the browser jumping to the top of the page; leave it out and the link works but the page scrolls.
What opens
Whichever consent interface that visitor was actually shown:
| Your banner | What the link opens |
|---|---|
| Category banner (GDPR) | The preferences dialog, with the categories and their current state |
| US opt-out | The opt-out dialog, with the visitor's current choice |
| IAB TCF | The CMP's second layer, purposes and vendors |
You do not have to know which of these your site runs, and you do not have to change the link if you switch templates later. On a site running both the GDPR and US templates, a visitor in Germany and a visitor in California click the same link and each gets the interface that applies to them.
Before the visitor has answered
On a TCF banner, nothing on the page is clickable until the visitor decides — that is what the standard requires, and your footer is behind it like everything else. Once they have answered, the link works normally.
On the other banners the link works right away, though there is little reason to use it: the banner is already on screen.
Turning the floating icon off
You cannot, and this is deliberate: it is the fallback that guarantees a visitor can always reach their consent again. What you can do is move it — the designer's Layout panel has all four corners — so it sits where it does not clash with a chat widget or a back-to-top button, or restyle it through custom CSS with the #cw-reopen-consent selector.