Consent Mode is a consent-aware way of running your analytics and marketing tags so they respect a visitor’s privacy choices without breaking your measurement. In practice, your site reads the visitor’s consent (via a CMP) and switches tag behavior accordingly: when consent is granted, normal tracking runs; when denied, tags avoid using identifiers (e.g., cookies) but can still send privacy-safe, aggregated pings for high-level metrics like Pageview and event counts.
How Consent Mode works (in plain English)
- A consent banner (CMP) collects the visitor’s choices.
- Those choices are exposed to your scripts (often through the DataLayer).
- Your tag loader (client- or Server-Side Container) configures each tag:
- With consent: full features (cookies, user/session linking, attribution).
- Without consent: send cookieless signals (no identifiers, no reading/writing cookies), so you still see traffic and core events.
- Downstream, your analytics can use statistical methods to model gaps from non-consenting traffic.
Typical behavior matrix
Consent state | Storage use | What gets sent | Key limitations |
---|---|---|---|
Granted | Allowed (e.g., first-party cookies) | Full events with Event Parameters | Normal attribution, Session stitching |
Denied | Blocked (no cookies/IDs) | Aggregated, cookieless pings | No user deduping, limited multi-visit attribution |
Related: First-Party Cookie / Third-Party Cookie, Measurement Protocol
Why it matters for analytics
- Continuity without creepiness: you preserve directional metrics (visits, key events) when consent is denied, while honoring privacy.
- Cleaner governance: a single consent signal drives all tags; fewer “rogue” scripts.
- Better modeling: separating consenting vs. non-consenting traffic improves transparency of any modeled results.
Mini example (quick math)
Say 10,000 visits today, 60% grant consent, and the average consenting user fires 3 key events:
- Observed consenting events = 10,000 × 0.60 × 3 = 18,000
- Non-consenting traffic still contributes cookieless pageview pings, so you can estimate total demand even without identifiers.
Implementation tips
- Centralize consent in the DataLayer so every tag reads the same state.
- Gate all identifiers on consent (IDs, cookies, localStorage, fingerprinting—don’t do it).
- Prefer first-party collection through a Server-Side Container if you need stricter control.
- Document exactly which events run in denied mode vs. granted mode to avoid metric drift.