# Google Consent Mode v2 setup in GTM: basic vs advanced

**Source:** https://cookiepanda.app/blog/google-consent-mode-v2-gtm-setup  
**Summary:** The four Consent Mode v2 signals, basic vs advanced mode, and a step-by-step Google Tag Manager setup you can verify in Tag Assistant.  
**Published:** 2026-11-12  
**Publisher:** Cookie Panda

---

## Key takeaways

Consent Mode v2 tells Google tags what each visitor agreed to, so they can adjust instead of breaking.

- Four signals matter for ads and analytics: ad\_storage, analytics\_storage, ad\_user\_data and ad\_personalization.
- Basic mode blocks Google tags until the visitor chooses; advanced mode loads them with consent denied and sends cookieless pings for modelling.
- In GTM, turn on Consent Overview, make sure a default state is set before any tag fires, and add consent checks to non-Google tags.
- Verify in Tag Assistant's Consent tab: you should see an on-page default and an update after the choice.

Google Consent Mode is how your consent banner tells Google's tags what a visitor agreed to. Instead of choosing between "tags on" and "tags off", Google Analytics and Google Ads adjust their behaviour to each visitor's choices. Version 2 added two signals for advertising data, and since March 2024 Google's EU user consent policy has relied on them: without them, EEA users are left out of the GA4 audiences you use in Google Ads, and Customer Match lists for the EEA need both new signals set.

This guide explains the signals, the difference between basic and advanced mode, and how to set it all up in Google Tag Manager (GTM) and check that it works.

## The consent signals {#the-consent-signals}

Google defines seven consent types. Four of them control advertising and analytics ([Google documentation](https://developers.google.com/tag-platform/security/concepts/consent-mode)):

| Signal | What it controls |
| --- | --- |
| `ad_storage` | Storage, such as cookies, related to advertising |
| `analytics_storage` | Storage related to analytics, such as visit duration |
| `ad_user_data` | Consent for sending user data related to advertising to Google (new in v2) |
| `ad_personalization` | Consent for personalised advertising, such as remarketing (new in v2) |

The other three, `functionality_storage`, `personalization_storage` and `security_storage`, cover things like language settings, recommendations and fraud prevention. They are useful for gating your own tags in GTM.

## Basic vs advanced mode {#basic-vs-advanced-mode}

The difference is what happens before the visitor makes a choice:

- **Basic mode.** Google tags do not load until the visitor interacts with the banner. If they decline, the tags never fire and nothing is sent to Google. Conversion modelling uses a general model.
- **Advanced mode.** Google tags load straight away with consent set to denied. While consent is denied they send measurements without cookies, which Google uses to build an advertiser-specific model of the conversions you cannot observe.

Advanced mode recovers more data, but it does send cookieless pings before consent. Basic mode sends nothing until the visitor agrees. Which one is right depends on your risk appetite and on what your regulator and legal team are comfortable with. Modelling also has minimum traffic thresholds, so small sites may see little benefit from advanced mode.

What Google tags do in each mode, before and after the visitor's choice.

## Set up Consent Mode v2 in GTM, step by step {#set-up-consent-mode-v2-in-gtm-step-by-step}

These steps assume Cookie Panda as your banner, but the GTM side is the same for any consent platform that supports Consent Mode v2.

### Step 1: Add the banner script before GTM {#step-1-add-the-banner-script-before-gtm}

Put the Cookie Panda script in your `<head>` above the GTM container snippet. Cookie Panda emits Consent Mode v2 signals automatically, along with the IAB TC and GPP strings, as visitors make or change their choices.

```html
<script
  src="https://sdk.cookiepanda.app/cookiepanda.min.js"
  data-cp-token="cp_xxx"
  async
></script>
<!-- Google Tag Manager container snippet goes below -->
```

### Step 2: Turn on Consent Overview {#step-2-turn-on-consent-overview}

In GTM, go to Admin → Container Settings and tick "Enable consent overview". A shield icon appears in the Tags list, showing which tags have built-in consent checks and which need extra settings ([GTM help](https://support.google.com/tagmanager/answer/10718549)).

### Step 3: Make sure a default is set before any tag fires {#step-3-make-sure-a-default-is-set-before-any-tag-fires}

Google requires the default consent state to be set on every page before any measurement or ad calls. In GTM, anything that sets defaults belongs on the "Consent Initialization - All Pages" trigger, which always fires first. If you set defaults in code instead, they look like this, with `wait_for_update` giving the banner time (in milliseconds) to send the visitor's stored choice:

```js
gtag('consent', 'default', {
  ad_storage: 'denied',
  analytics_storage: 'denied',
  ad_user_data: 'denied',
  ad_personalization: 'denied',
  wait_for_update: 500
});
```

You can also add a `region` parameter with ISO 3166-2 codes to apply different defaults in different places; the most specific region wins. Check in Step 6 that only one default reaches your tags, so a hard-coded default does not contradict the one your banner sets.

### Step 4: Choose basic or advanced {#step-4-choose-basic-or-advanced}

- **For advanced mode,** leave your Google tag, GA4 and Google Ads tags on their normal triggers. Their built-in consent checks read the signals and send cookieless pings while consent is denied.
- **For basic mode,** stop Google tags from firing until consent: in each tag, open Advanced Settings → Consent Settings, choose "Require additional consent for tag to fire" and add `analytics_storage` or `ad_storage`. Alternatively, let Cookie Panda's [Prior Cookie Blocking](page:/features/blocking) hold the tags back until the visitor opts in.

### Step 5: Gate your non-Google tags {#step-5-gate-your-non-google-tags}

Consent Mode only changes how Google's own tags behave. Meta, TikTok, LinkedIn and other tags in your container ignore it unless you add consent checks. For each one, set "Require additional consent for tag to fire" with the matching signal, usually `ad_storage` for advertising pixels.

If you prefer to trigger tags on the consent decision itself, Cookie Panda dispatches a `cookiepanda:consent` event on the document with the chosen categories. A small Custom HTML tag can forward it to the data layer:

```js
document.addEventListener('cookiepanda:consent', function (e) {
  window.dataLayer = window.dataLayer || [];
  window.dataLayer.push({
    event: 'cookiepanda_consent',
    cp_categories: e.detail.categories
    // { necessary, analytics, advertising, preferences }
  });
});
```

Then create a Custom Event trigger for `cookiepanda_consent` and use it on the tags that should fire after a choice.

### Step 6: Optional settings {#step-6-optional-settings}

- `url_passthrough` passes ad click information through URLs when ad cookies are denied, to improve measurement.
- `ads_data_redaction` redacts ad click identifiers when `ad_storage` is denied. It has no effect once ad storage is granted.

## How to verify it in Tag Assistant {#how-to-verify-it-in-tag-assistant}

1. In GTM, click Preview and open your site in Tag Assistant, in a private window and from an EEA location if possible.
2. Before touching the banner, select the first event and open the Consent tab. The "On-page Default" column should show the four signals as denied. An empty Consent tab means Consent Mode is not implemented.
3. Click "Accept all". A new event should show the signals as granted in the "On-page Update" column.
4. Repeat with "Reject all" and check that the update stays denied and that your gated non-Google tags did not fire.
5. In your browser's network tab, requests to Google carry a `gcs` parameter with the ad and analytics storage state, and a `gcd` parameter with more detail. If they change after your choice, the signal is getting through ([Google's debugging guide](https://developers.google.com/tag-platform/security/guides/consent-debugging)).

## Common mistakes {#common-mistakes}

- Setting only `ad_storage` and `analytics_storage`, the v1 signals, and forgetting `ad_user_data` and `ad_personalization`.
- Loading GTM before the banner, so tags fire before any default exists.
- Assuming Consent Mode covers Meta or TikTok. It does not.
- Never sending an update when a returning visitor's stored choice loads, so every page view looks like "denied".

Running a store? Our [Black Friday consent checklist for Shopify and WooCommerce](page:/blog/black-friday-cookie-consent-shopify-woocommerce) covers pixels and campaign apps. For everything else Cookie Panda connects to, from GTM to signed webhooks, see [Integrations & Webhooks](page:/features/integrations) and the [frameworks and signals docs](page:/docs#frameworks).

## Consent Mode v2, without the dataLayer engineering

Cookie Panda emits all four Consent Mode v2 signals, plus IAB TCF and GPP strings, from one script tag.

Free for one domain. No credit card required.
