Free cookie banner with Google Consent Mode v2
Tick your analytics and paid campaign tools, set the design, paste the code above the Google Tag Manager script. No account, no page limit and designed for Belgium.
- €0
- no account, no subscription
- 4
- languages based on the page: FR, NL, DE and EN
- 6 months
- choice duration, the one the Belgian DPA considers reasonable
What the banner does
- Consent Mode v2 set to denied
- The 4 signals stay denied until the visitor chooses.
- Accept, refuse or configure
- 3 CTAs on the same level and the same size.
- Change your mind at any time
- A persistent icon reopens the choice and deletes refused cookies.
- The code stays with you
- It runs on your site, without going through my servers.
Set up your cookie banner
The preview and the code follow every setting.
1. Your tools
Tick the ones in your Google Tag Manager container. The banner text adapts.
2. Your company
The Belgian DPA asks you to name the controller and give access to the list of cookies.
3. Appearance
Position
Page background
Colour code not recognised. Example: #0a2540 or rgb(10, 37, 64).
Accept and Refuse take the CTA colour, Configure stays transparent. The text colour is calculated for you.
Your CTAs barely stand out from the banner. Choose a colour with more contrast.
Refuse CTA style
The "Accept" choice stands out more, but the Belgian DPA lists nudging through colour as a technique to avoid.
Preview
Tick at least one tool to see the banner.
What Google receives
Your code
Table for your cookie policy
It covers the ticked tools. Add your contact details, your other cookies and any transfers outside the EU.
Install the banner compliant with Consent Mode v2
Paste the code at the top of the head
Put it on all your pages, at the very top of the
<head>, above Google Tag Manager. Google asks that the default consent runs before any tag.Set up your tags in Google Tag Manager
The banner code activates Consent Mode v2: your container receives the consent on every page. To check it tag by tag, enable the consent overview (Admin, Container Settings).
Google tags: nothing to change. GA4, Google Ads and the Conversion Linker read the consent on their own. After consent, they set their cookies and what follows is sent with consent.
Meta and LinkedIn tags: they do not read this consent. Add the additional consent
ad_storageto them. Then fire their page view on the custom eventconsent_update, filtered onconsent_adsequal togranted.Check in the console and with Tag Assistant
Open the browser console (F12) and click Accept. The banner writes
[XLTAG] GA4: the tag received the consent, or warns you if nothing goes out within 10 seconds.For the details, open Tag Assistant and enter your site URL. In the Consent tab, the On-page Default column shows denied everywhere, then the On-page Update column changes to granted. The Tags tab shows the tags that fired.
Complete your cookie policy
Paste the table generated on this page. The Belgian DPA also asks you to date it, give it a version number and keep previous versions.
XLTAG is in no way responsible for your cookie policy. It is solely up to you to check its compliance based on your use and its purposes.
What the Belgian DPA asks, what the banner does
The Data Protection Authority details its expectations on its page cookies and other trackers (in French and Dutch).
Refuse on the same level as accept
Refuse, Configure and Accept side by side, at the same size. Refuse and Accept share the same style.
An active choice, by purpose
Configure opens a second level: traffic measurement and advertising are chosen separately, boxes unticked. Browsing the site does not count as consent.
The controller and purposes in view
The first level names your company, counts your partners and names their purposes.
The language of the target audience
The text follows the page language: French, Dutch, German or English.
Withdrawal as simple as consent
The Cookies icon or a footer link reopens the choice in 1 click. A withdrawal deletes the first-party cookies concerned.
A time-limited preference cookie
The choice expires after 6 months, then the question comes back. It also comes back when you add a tool.
By default, Accept and Refuse look the same
This is the good example in the Belgian DPA checklist, which lists nudging through colour among the techniques to avoid.
Would you rather have Accept stand out? The transparent style remains available. No model is imposed, each case is examined on its own, but this choice is yours.
What the banner does not do
- Scan your site: the table covers the 4 tools offered, it's up to you to add your other cookies.
- Keep a central register: the choice and its date stay in the visitor's cookie.
- Integrate the TCF: to show AdSense, Ad Manager or AdMob ads, Google requires a certified CMP. For your Google Ads tags and remarketing, Google expects the Consent Mode v2 signals, which the banner sends.
- Replace legal advice: I am a digital analyst, not a lawyer.
Questions about the free cookie banner
Any doubts about your installation?
The banner handles consent. The rest of your tracking deserves the same care.
Have your installation checked
I look at your tags, your consent and your conversions during a free first call. Reply within 48h.
Get in touchLimit lost conversions
Ad blockers and limited cookies cost you conversions. Server-side tracking reduces this loss, for the same consent.
See the server-side package