Home > Docs > Configuring Google Tag Manager to Capture Consent Signals from CMP

Configuring Google Tag Manager to Capture Consent Signals from CMP

Last updated on May 9, 2025

Configuring Google Tag Manager (GTM) for Google Consent Mode v2 is essential for businesses seeking to balance data-driven insights with user privacy preferences. Google Consent Mode allows websites to adjust Google Tag’s behavior based on the user’s consent status. This article explains the necessary steps that need to be taken to configure GTM and modify tag behavior, such as enabling or disabling tracking based on consent signals sent by the CMP – WebToffee Cookie Consent.

The Google Consent Mode operates in two different modes, and the tag behaviors change based on the configured mode. The modes and the tag behaviors are elaborated below:

  • Basic Mode – When you use basic consent mode, Google tags don’t load until the user interacts with the consent banner. No data is sent to Google before the user provides consent, and once consent is given, Google tags load and share consent states. If the user doesn’t consent, no data is sent, and Google tags are fully blocked.
  • Advanced Mode – In advanced consent mode, Google tags load when a user visits the website or app. Initially, consent is set to “denied” by default, and tags send cookieless pings until the user interacts with the consent banner. Once the user grants consent, Google Tags sends complete measurement data.

Step 1: Sign Up/ Create a Google Tag Manager Account

If you don’t have a Google Tag Manager account, sign up for one by visiting Google Tag Manager and follow the account creation process.

Step 2: Create a new container

The Container is where you’ll manage and deploy your website’s tags, triggers, and variables. Follow the below steps to create and install a new container:

  1. In Tag Manager, click the Accounts tab > Create Account.
Creating Account - Google Tag Manager
Creating Account – Google Tag Manager
  1. Enter an Account Name and select the Country for the account.
  2. Enter the Container name and select the container type.
  3. To create your container, click Create and agree to the Terms of Service
Creating Container - Google Tag Manager
Creating Container – Google Tag Manager

Step 3: Install the container

Upon container creation, install the necessary integration code snippets on your website. Copy and paste the corresponding code snippets into the <head> and <body> tags.

Installing Container - Google Tag Manager
Installing Container – Google Tag Manager

Step 4: Automated mapping of consent types

GDPR Cookie Consent CMP automatically maps the consent types to the cookie categories and sends it to the Google Tag Manager using gtag(). The table below lists the mapping scheme that the CMP uses:

Consent TypeCookie CategoryPurpose
ad_storageadvertisementTo enable advertisement cookies.
analytics_storageanalyticsTo enable analytics cookies.
functionality_storagefunctionalTo enable functional cookies for website functionality and settings.
personalization_storagefunctionalTo enable functional cookies for user personalization.
security_storagenecessaryTo enable necessary cookies for website security and protection, user UI preferences, etc. Such cookies do not require consent.
ad_user_dataadvertisementTo enable advertisement cookies to set consent for sending personal data to Google core platform service.
ad_personalizationadvertisementTo enable advertisement cookies to use data for ad personalization such as remarketing.

Enable the Consent Overview feature in GTM. It helps you understand and manage consent settings in your GTM container, ensuring compliance with privacy regulations. This option will provide a visual representation of the tags, categorized into those that are “Consent Not Configured” (no action taken) and “Consent Configured” (with consent settings applied). 

  • In GTM, go to Admin > Container Settings
  • Under Additional Settings, find and select Enable consent overview.
Consent overview – GTM Container Settings

Aligning third-party tag behavior with CMP consent signals

Aligning third-party tags to respond to consent signals sent by a CMP would allow the site owner to modify how this tag behaves alongside your consent tools. All the tags in the GTM will check for the status of the consent types marked as built-in, namely ad_storage, ad_personalization, ad_user_data, and analytics_storage. The site owner can also force the tag to listen to additional consent types by setting the Additional Consent Checks option.

For the third-party tags to align with the consent signals, the site owner must explicitly state the consent type that the tag must listen to from the Additional Consent Checks option.

  1. In the GTM, go to the Tags tab. Click on the third-party tag, then click on Advanced Settings.
  2. Click on Consent settings.
Advanced consent settings - Google Tag manager
Advanced consent settings – Google Tag manager
  1. From the listed option, select Require additional consent for tag to fire. Click on the Add required consent button.
Additional consent - Google Tag Manager
Additional consent – Google Tag Manager
  1. Click inside the text box, and from the drop-down, select the consent type the tag must listen to for firing.
Consent Tag - Google Tag Manager
Consent Tag – Google Tag Manager
  1. Click on Save and commit the changes.

The earlier steps will configure the tag to listen to the set consent types. The third-party tags will only fire when the user accepts the appropriate mapped cookie categories in the banner.