---
title: "Google Consent Mode v2"
description: "Configure direct-load and GTM-template consent commands and verify their runtime state."
url: "https://cookiebeam.com/docs/integrations/google-consent-mode"
lang: "en"
---

# Google Consent Mode v2

Configure direct-load and GTM-template consent commands and verify their runtime state.

CookieBeam sends Google Consent Mode v2 signals for Google tags. Other vendors do not consume these signals. Control them through [blocking](https://cookiebeam.com/docs/configure/blocking) and category assignment.

Direct banner loading and loading through a GTM template use different startup sequences. Configure the path you deploy.

## Category mapping

The base category mapping is:

| CookieBeam category | Consent Mode v2 keys |
| ------------------- | -------------------- |
| `necessary` | `security_storage` |
| `functional` | `functionality_storage` |
| `analytics` | `analytics_storage` |
| `marketing` | `ad_storage`, `ad_user_data`, `ad_personalization` |
| `preferences` | `personalization_storage` |

A category not in this table maps to no key.

There is one compatibility rule. When the banner has no separate `functional` category, accepted `preferences` also grants `functionality_storage`. During default-state calculation, an accepted `necessary` category also grants `functionality_storage` when `functional` is absent.

## Direct banner loading

The generated direct-load bundle enables a consent `default` command on load. The core integration can skip that command when `setDefaultsOnLoad` is false, but generated CookieBeam bundles currently set it to true.

For a visitor with valid stored consent, the default reflects the stored categories. A parseable, non-pending stored record can also supply its categories when it is invalid for the current configuration. When no stored categories are available through either path, the default starts from the banner's `readOnly` categories and the matched regional rule's Consent Mode default categories, then applies any explicit regional Consent Mode key overrides.

The default payload includes `wait_for_update` when the visitor does not have valid stored consent. The fallback is 2,000 milliseconds when no value is supplied. `url_passthrough` is not part of the consent payload. CookieBeam sends it separately with `gtag('set', { url_passthrough: true })` when enabled.

## Loading through a GTM template

The GTM template sets its own defaults. Without regional template settings, its conservative global fallback starts `ad_storage`, `ad_user_data`, `ad_personalization`, `analytics_storage`, and `personalization_storage` at `denied`, and starts `functionality_storage` and `security_storage` at `granted`. When regional template settings exist, the template issues each row's configured defaults instead; those fields can be `granted`. If no configured row is global, the template also adds the conservative global fallback.

The template also applies URL passthrough as a separate setting. The direct-load settings in the banner dashboard do not configure template defaults.

After the template default:

- A returning visitor with valid stored consent always receives a consent `update` from the runtime.
- A new visitor receives an initial runtime `update` only when explicit regional defaults exist and differ from the template defaults.
- A visitor choice sends a consent `update` with the resolved category state.

## Configure and publish

For direct loading:

1. Open the banner's **App Integrations** page.
2. In **Google Consent Mode**, enable the integration and set **Wait for Update**, **Ads Data Redaction**, and **URL Passthrough** as needed.
3. Click **Save Consent Mode Settings**.
4. Publish the banner.

For a GTM-template installation, configure the initial defaults in the template instead. The banner's direct-load defaults do not replace them.

## Measurement limits and prerequisites

CookieBeam sends consent commands; Google performs any modeling in its own reporting. Modeled outcomes are aggregate estimates, not a restoration of individual visitors' conversion histories.

For Google Ads, configure conversion tracking and publish the banner with Consent Mode enabled. Install CookieBeam before the Google tag's config and event commands. Advanced Consent Mode lets Google tags send cookieless pings with denied storage; blocking those tags until consent is the basic path. Basic implementations may receive general modeling, but cannot supply the same advertiser-specific calibration data. Google's current eligibility checks include 700 daily ad clicks over seven days per country and domain grouping, plus correct implementation. Meeting a threshold does not promise a particular recovery rate. See [Google Ads modeling requirements](https://support.google.com/google-ads/answer/10548233) and [basic versus advanced setup](https://support.google.com/google-ads/answer/14009635).

GA4 behavioral modeling is separate from Google Ads conversion modeling. It requires advanced Consent Mode across all pages, sufficient denied and granted traffic, and an eligible property. Blended reporting is needed to display it. See [GA4 prerequisites and reporting limitations](https://support.google.com/analytics/answer/11161109).

Choose the tag behavior appropriate to your site's requirements and verify the published setup. Enabling the consent integration alone does not install Google tags, enable modeling, or bypass your blocking rules.

## Verify commands

Use a clean browser profile and inspect `window.dataLayer` before and after a choice:

```js
window.dataLayer
window.CookieBeamGTM?.getConsent()
```

A direct load should contain a consent `default` command. A returning template load should contain the template default followed by a runtime `update`. After a visitor choice, confirm an `update` carries the expected storage states.

Consent updates also push `cookie_consent_update`. Accepted categories can additionally push `cookie_consent_marketing`, `cookie_consent_statistics`, and `cookie_consent_preferences`.

If no consent command appears, confirm the published bundle has Consent Mode enabled and identify whether the page uses direct loading or the GTM template. Do not diagnose a template load from the direct-load settings.
