GUIDE

Tracking Works Before Consent But Breaks After — What's Going On

This is the more confusing sibling of "GA4 not receiving data" — because in this case it clearly was working. Then a visitor does the "right" thing, accepts your cookie banner, and tracking goes dark. Here's the specific pattern behind it.

Why this is backwards from what you'd expect

Normally consent gating means analytics is silent until consent is granted, then starts working — that's the compliant, expected behaviour. What we're describing here is the opposite: a hit fires on page load (before any consent decision), and then nothing fires afterward even once consent is explicitly accepted. That's not a compliance feature working correctly — it's a genuine bug.

The most common cause: a stale consent state reference

Many consent-management setups grant a "default" analytics state on page load (sometimes unintentionally, via a misconfigured default), which lets the first hit through. Then, when the visitor actually clicks "Accept," the consent-management platform updates its own internal state — but the trigger controlling your GA4 tag was configured to check consent state once

The second most common cause: two consent systems talking past each other

If a site uses a third-party consent-management platform (CMP) alongside Google Tag Manager's own built-in consent settings, both need to agree on the same signal. It's common for the CMP to update its own cookie correctly while never actually calling gtag('consent', 'update', ...) — meaning GTM's own consent state never learns that anything changed, regardless of what the visitor actually clicked.

How to diagnose it on a specific page

  • Open the page fresh (clear cookies first) and check whether a hit fires before you interact with the consent banner at all
  • If yes, that's already worth investigating — it suggests default consent is granted when it likely shouldn't be
  • Click "Accept" on the banner, then check whether a new hit fires afterward
  • If no new hit fires, open GTM Preview mode and manually accept — look at exactly which trigger conditions the GA4 tag depends on, and whether they're tied to a consent state that only gets checked once

This exact pattern is one of the checks we run automatically on every page.

Run a free check on your own site →
← Back to all guides