Skip to main content

Integrate Axeptio via Google Tag Manager

Written by Alexandre Dias Da Silva

This article is part of the Integration series. Before following the guide below, make sure you have reviewed the general overview article Choose your Axeptio integration method.

Are you already loading Axeptio via another method (CMS plugin, hardcoded, or other)? In that case, you do not need to follow this guide. If you are looking to manage your cookie blocking using GTM, consult this article.

Basic GTM Functionality

This article does not cover Google Tag Manager account and container creation. For installation instructions, consult the official documentation.

Google Tag Manager works primarily in two parts:

  • Tags: these are the snippets of code that you will inject into your site (tracking code, conversion pixel, etc.)

  • Triggers: this is what will cause the injection of tags on your site. They allow you to define the condition for injecting your tag (💡 on every page load, after a purchase, etc.)

Load Axeptio via GTM

🍪 If you are already loading Axeptio via another method (script, plugin, etc.), you do not need to reload Axeptio in GTM

Go to your GTM interface:

  • Select the Tags tab in the left menu

  • Then click on New

Capture_d_e_cran_2022-03-08_a__11.27.28.png

Click in the Tag configuration rectangle. In the page that just opened:

  • Then in the list that appeared, click on "Discover more tag types in the gallery":

  • Search for "Axeptio CMP" and select the template:

  • Add the template to your workspace. You should now have this in your tag:

  • Now fill in your project ID in the Project ID field.
    (Optional) You can also enter the name of your cookie version if you have multiple cookie widget configurations:

All that remains is to choose a trigger:

  • Click on the Triggering rectangle

  • Select the trigger named Consent Initialization - All Pages so that Axeptio is loaded first. This trigger is the first event in the GTM lifecycle — it ensures that default consent signals are set before your Google tags (GA4, Ads, etc.) execute. If you use another trigger (All Pages, DOM Ready, etc.), your Google tags may fire without a consent signal, which causes data loss, GA4 traffic displayed as "Unattributed", or consent signals applied too late.

  • Finally, give your tag a name and save it:


Your Axeptio tag is now fully configured. All you have to do now is publish your GTM container so that your changes are live on your site.

📌 If you use Google Analytics 4 and/or Google Ads, you will need to configure Consent Mode v2 in this same tag. You will find all the information on implementing Consent Mode v2 here: Google Consent Mode v2 Installation

Did this answer your question?