Deployment via Google Tag Manager
You can insert the Cookienovo script into the section <head>
using Google Tag Manager (GTM) too. Follow the steps below.
Recommended: the Cookienovo template from the Template Gallery
The simplest and, for Google Consent Mode v2, the most reliable option is our official template from the GTM Community Template Gallery. The template sets the default consent state before any other tag, sends Cookienovo's Google developer ID, applies a returning visitor's stored choice right away and loads the banner.
- In the container, open Templates in the left panel and, under Tag Templates, click Search Gallery.
- Search for Cookienovo and click Add to workspace.
- Under Tags (Tags) click New (New) and choose the tag type Cookienovo.
- In the field Site token paste your site token — it is the value of the site-token attribute in the banner code, which you find in Cookienovo in the Setup wizard.
- Keep Consent Mode v2 enabled and the default value denied for functional, marketing and analytics cookies. If you need different defaults for some countries, add them in the Google Tag Configs group, in the Region specific table (e.g. SK,CZ).
- As the trigger, choose Consent Initialization – All Pages.
- Click Save.
- In the top right, click Submit (Submit) and then Publish (Publish), for the changes to take effect.
Google tags (GA4, Google Ads) in the same container need no changes — they have built-in consent checks and follow the state set by the template and the banner. Do not add the Cookienovo banner code to the website separately; the template loads it.
Updating the template
If you already use the template, a notice about a new version appears next to it under Templates. Open it, choose update, review the changes and publish the container again. The latest version (November 2026) applies a returning visitor's stored choice as soon as the page loads and adds the personalization_storage consent type.
Verification
In Preview mode, open Tag Assistant and on the Consent tab check that before the choice ad_storage, analytics_storage, ad_user_data and ad_personalization are Denied and change to Granted after clicking Allow all. A live example is available at cookienovo.com/cmp-test/gtm.
Alternative: Custom HTML tag
- Sign in to your account Google Tag Manager.
- Select the container you want to add the code to. If you don't have one, create it via Create account and follow the instructions.
- Click the container name to open the main GTM interface.
- In the left navigation panel, click Tags (Tags).
- Click New (New) and choose the tag type Custom HTML (Custom HTML).
- Paste the Cookienovo script into the HTML field.
- Set the trigger to Initialization – All Pages, so it loads as early as possible.
- Click Save.
- In the top right, click Submit (Submit) and then Publish (Publish), for the changes to take effect.
-
Finally, insert the GTM container code itself into the
<head>of your website — just before the closing tag</head>.
After these steps, the Cookienovo script should load correctly via GTM. We recommend testing the implementation and verifying that the banner works.
Google Consent Mode v2:
when loading Cookienovo via GTM, our generated script automatically includes inline default consent settings that set the Consent Mode v2 parameters
before
GTM runs. This ensures compliance even with asynchronously loaded Google tags. The inline script sets ad_storage, analytics_storage,
ad_personalization
and ad_user_data
by default to 'denied', together with wait_for_update:500
for optimal CMP loading.