Key facts
  • Loading OneTrust or Cookiebot asynchronously inside GTM causes GA4 and Google Ads to initialize before consent defaults exist, producing broken gcd=13l3l3l3l1 hits.
  • Always declare gtag('consent','default',...) synchronously in <head> above the GTM snippet with EEA/UK defaults set to denied and wait_for_update: 500.
  • In Server-Side GTM, inspect incoming gcs/gcd consent flags before dispatching Meta CAPI, LinkedIn CAPI, or CRM webhooks so non-Google tags stay strictly gated.
  • Verify any Chrome DevTools /g/collect request instantly in our free Consent Mode v2 Decoder (/tools/consent-mode-decoder/).
The #1 Consent Mode v2 Bug

Loading OneTrust or Cookiebot asynchronously inside Google Tag Manager causes a race condition where GA4 and Google Ads tags initialize before consent defaults exist (visible as gcd=13l3l3l3l1). Always declare gtag('consent', 'default', ...) synchronously in <head> above the GTM snippet, set EEA/UK defaults to denied, and let your CMP fire strictly gtag('consent', 'update', ...) upon user choice.

Consent Mode v2 Script Load Order & Expected gcd States

Load Sequence StepWhat ExecutesExpected EEA gcd State
1. Inline <head> Script (First)gtag('consent','default',{...denied})p (denied default declared)
2. CMP Script (OneTrust / Cookiebot)Renders banner & listens for choiceRemains p until user clicks
3. First-Party sGTM ContainerInitializes GA4/Ads respecting defaultSends cookieless modeling ping only
4. User Clicks Accept / DeclineCMP fires gtag('consent','update',...)r (granted) or q (declined)

Synchronous Consent Default Order (Above GTM)

<script>
window.dataLayer = window.dataLayer || [];
function gtag(){ dataLayer.push(arguments); }

// 1. Strict EEA/UK default BEFORE GTM loads
gtag("consent", "default", {
  ad_storage: "denied",
  ad_user_data: "denied",
  ad_personalization: "denied",
  analytics_storage: "denied",
  wait_for_update: 500,
  region: ["AT","BE","BG","HR","CY","CZ","DK","EE","FI","FR","DE","GR","HU","IS","IE","IT","LV","LI","LT","LU","MT","NL","NO","PL","PT","RO","SK","SI","ES","SE","GB","CH"]
});

// 2. Non-EEA fallback default (aligned to counsel policy)
gtag("consent", "default", {
  ad_storage: "granted",
  ad_user_data: "granted",
  ad_personalization: "granted",
  analytics_storage: "granted"
});
</script>
<!-- 3. Now load OneTrust/Cookiebot + first-party sGTM script -->

Server-Side GTM Enforcement & Verification Tools

In your sGTM container, inspect the incoming gcs/gcd parameters before dispatching Meta CAPI, LinkedIn CAPI, or custom CRM webhooks, blocking third-party ad tags whenever ad_user_data is denied while letting Google receive anonymous cookieless modeling pings. Verify any DevTools hit immediately with our free Consent Mode v2 Decoder, check your raw HTML defaults in our Live Funnel Leak Inspector, or read CMP vendor docs: Cookiebot Help Center, OneTrust Support, and Stape sGTM Docs.

Technical FAQs

How do I verify if our Consent Mode v2 default is firing in the right order?
Open Chrome DevTools Network tab, filter for /g/collect, copy the request URL, and paste it into our free Consent Mode v2 Decoder (/tools/consent-mode-decoder/). If gcd contains the letter 'l' (e.g., 13l3l3l3l1), no default fired prior to GTM initialization.
What is the difference between Basic and Advanced Consent Mode v2?
Basic Consent Mode blocks Google tags completely until the user grants consent (zero cookieless pings, weaker modeling). Advanced Consent Mode initializes with all 4 EEA signals denied before GTM loads, sending anonymous cookieless pings that enable Google's behavioral and conversion modeling while blocking third-party ad cookies.
Does fixing client-side Consent Mode v2 automatically gate Meta CAPI and LinkedIn CAPI inside sGTM?
No. Server-Side GTM tags for Meta CAPI, LinkedIn CAPI, and custom CRM webhooks must explicitly check incoming consent state (ad_storage and ad_user_data) via server triggers or tag consent checks so denied EEA visitors never fire third-party marketing APIs.