Menu
All schedule 8 min read

Cookie Consent and Analytics: Why the Numbers Drop

Faraz Frank

Faraz Frank

November 23, 2026

Cookie Consent and Analytics

The message usually arrives three weeks after the banner goes live: sessions are down, conversions are down, and someone wants to know which plugin broke the tracking.

The tag is rarely the culprit. What changed is the order in which four things happen on the page, and a drop after consent is a predictable result of that order. Reading the sequence explains most of the numbers before anyone opens a settings screen.

The Sequence on Every Page Load

  1. The HTML arrives. At this point nothing has been measured and nothing has been stored.
  2. The head is parsed. A consent default has to be declared here, before any tag that measures.
  3. The Google tag loads — through gtag.js directly or inside a Tag Manager container.
  4. The banner renders and the visitor chooses, or ignores it.
  5. An update event fires, and every hit after it carries the new state.

Every failure in this article is one of those five steps in the wrong position. A default declared after the tag has loaded is not a default. A banner that renders before the default is declared leaves a window in which the tag runs with no instruction at all.

What Each Position Sends

Google documents two implementations in its consent mode overview, and the difference decides what your reports show:

Consent mode offers two implementations: basic, which blocks tags until consent; and advanced, which loads tags with default settings and adjusts behavior based on consent, allowing for more detailed conversion modeling.

MomentBasicAdvanced
Before the visitor choosesNothing sentCookieless ping, no identifier stored
After “reject”No hits at allCookieless pings, modeled in aggregate
After “accept”Full hitsFull hits
What Analytics showsOnly consenting visitorsAll visitors, partly estimated

Basic is the smaller number and the cleaner claim. Advanced is the larger number and the estimate. Neither is wrong, and picking one without knowing which is running is how a reporting argument starts.

Why Ordering Is Not a Setting

Google’s setup guide is unusually direct about this:

The order of the code here is vital. If your consent code is called out of order, consent defaults won’t work.

It also says the quiet part: “By default, no consent mode values are set.” An unconfigured site is not in basic mode or advanced mode. It is in neither, which in practice means tags behave as if consent had been granted.

That is the state most “the banner broke analytics” sites are actually in, in reverse: the banner collects choices, the tag ignores them, and the numbers do not move because nothing was ever gated.

The Check That Settles It

Byte offsets in the raw HTML tell you which instruction comes first. This runs against any URL and needs nothing but curl.

URL="${1:-https://example.com/}"
html=$(curl -sS -A "Mozilla/5.0" "$URL")

printf '%s' "$html" | grep -boE "consent',[[:space:]]*'default" | head -n 1 \
  || echo "no consent default in HTML"

printf '%s' "$html" | grep -boE "googletagmanager\.com/(gtag|gtm)\.js" | head -n 1 \
  || echo "no Google tag in HTML"

Two numbers, both byte positions in the same document. The smaller one comes first.

  • Default first, tag second. Ordering is correct. Whatever the report says, the cause is downstream.
  • Tag first, default second. The tag loaded before it was told anything, so pre-consent behaviour is whatever the container defaults to.
  • No default in the HTML. Either the site is not using consent mode, or the default lives inside a Tag Manager container, where this check cannot see it. Open Tag Assistant and look at the container instead of the page source.

That third line is the honest limit of the check. It reads the document, not the container, and a GTM-first setup hides most of the logic behind one script.

Where the Drop Is Real

Three mechanisms produce a genuine fall in reported traffic, and none of them is a bug.

The denominator changed. Only consenting visitors are counted in basic mode. If a third of your EU visitors reject, EU sessions fall by roughly that third the day the banner ships. The traffic did not leave; the measurement did.

Consent rates are not uniform. A visitor from a paid campaign, a first-time visitor, and a returning customer do not answer a banner the same way. The mix shifts, which moves channel totals even when each channel behaves as before. This is the reason a 12% sitewide drop can hide a 30% drop in one channel and no change in another.

Modeling fills gaps in aggregate, not in rows. Google’s own description of the mechanism:

When visitors deny consent, instead of storing cookies, tags send pings to Google. If you are using Google Analytics, Google fills the data collection gaps with conversion modeling and behavioral modeling.

Modeled data is estimated at the aggregate level. It restores counts, not sessions. A funnel built from user-level exploration will look thinner than the aggregate report, and that gap is expected rather than evidence of a fault.

Where the Drop Is Not Real

The other half of the drop usually comes from the implementation, and it is worth ruling out before touching the tag.

  • Defaults scoped globally instead of by region. Google recommends the opposite: “It is best practice to scope the default consent settings to the regions where you are surfacing consent banners to your visitors.” A global denied default treats a visitor in Texas like one in Berlin and costs you traffic you were entitled to measure.
  • The banner reloads the page. Some implementations refresh after a choice. Two page views per visit inflates some numbers and destroys session attribution, and it usually gets blamed on the tag.
  • Rejecting deletes the client ID. Without storage, a returning visitor cannot be recognised on the next visit, so a loyal cohort reads as new users. The sessions are real; the retention metric is not. Attribution suffers first, which is the subject the affiliate tracking piece takes apart.
  • The tag never fires at all. A CMP that blocks all tags until consent, with a banner that fails on mobile, produces a traffic cliff rather than a slope. Test on a phone before reading a single report.

What Version 2 Added

Consent mode was updated in November 2023 with two parameters that did not exist before, ad_user_data and ad_personalization. Google’s guidance is blunt about the implication: “If you already use consent mode, upgrade to consent mode v2.”

Those parameters govern advertising use of the data, not whether a page view is counted. A site that never upgraded will still see sessions where it expects them and will see remarketing audiences shrink instead. The symptom points at Ads, and the cause sits in the banner configuration — which is why the two complaints often arrive in the same week from different teams.

The Exemption Almost Nobody Qualifies For

France’s data protection authority publishes the clearest description of the one route that removes the banner entirely. CNIL’s Sheet n°16 lists the conditions for audience measurement that is exempt from consent:

  • inform users of the use;
  • give them the ability to object;
  • limit the purpose to audience measurement and A/B testing;
  • do not cross-check the data with other processing;
  • limit the tracer to a single publisher;
  • truncate the last byte of the IP address;
  • limit the tracker lifetime to 13 months.

Then the sentence that decides most projects: “Most large audience measurement offerings do not fall within the scope of the exemption, regardless of their configuration.”

The exemption is a design constraint, not a checkbox. Truncating the IP and refusing cross-site joins is something you can do with a self-hosted tool and cannot do with a third-party tag that also feeds advertising systems. That is the honest reason a privacy-first analytics install is a different product rather than a different setting, as the zero-knowledge analytics piece sets out.

Two caveats keep this from becoming a loophole. CNIL’s reading applies to French ePrivacy enforcement and may not travel; the UK regulator’s cookies guide instead stresses that consent must be “actively and clearly given”. And the GDPR’s own definition in Article 4 still applies on top of whatever the national cookie rule says: “any freely given, specific, informed and unambiguous indication of the data subject’s wishes”.

What to Check Before You Blame the Tag

  1. Run the byte-offset check. Confirm the default precedes the tag, or find out that it does not.
  2. Read the default’s region array. No region means everywhere, which is a decision, not a default.
  3. Open Tag Assistant and load the page with consent denied. Confirm the tag fires, sends its ping, and reports the denied state. A tag that never fires is a blocking bug.
  4. Check duplicate page views. Divide page views by sessions. A number near 1.0 is normal; 2.0 means something is firing twice.
  5. Compare the same regime. A week under the banner against a week before it is not a comparison. Use two consented weeks against each other, or accept that the difference includes the banner itself.
  6. Bring in an independent series. Search Console clicks and server-side request logs do not ask anyone for permission. If those hold steady while Analytics falls, the site did not lose traffic.

That sixth check is the most useful one, and it is the one nobody runs. Two measurement systems that agree are worth more than one that has been argued about.

Reporting It Without Pretending

Do not backfill the gap with estimates and do not silently compare across the change. Annotate the launch date in the property, state the mechanism in one sentence, and keep the old series visible next to the new one.

A workable sentence for a client report: “From 14 October, analytics counts only visitors who accepted the banner, so totals are not comparable with earlier months; Search Console clicks are unchanged over the same period.” That is a fact, not a defence.

The banner also costs something the analytics conversation tends to ignore. A consent library is a third-party script in the critical path, and the page speed guide covers what one more blocking request does to a mobile page. If the banner is slow, some of the “lost” sessions are visitors who left before it rendered — the same loss mode as an intrusive overlay, which the pop-up analysis documents from the marketing side. The PageSpeed walkthrough shows how to see the cost in a trace.

This is an engineering note, not legal advice. Cookie rules are enforced nationally, and the lawful basis for a specific install is a question for whoever signs the privacy notice. The GDPR compliance checklist covers the paperwork that question produces.

FAQ

Does consent mode lose data?

It loses rows, not totals, in advanced mode. Visitors who reject are still counted through cookieless pings and modeling, so aggregate sessions and conversions are estimated rather than dropped. In basic mode the loss is real until someone accepts.

Basic or advanced — which should a site use?

Basic if the priority is an unambiguous claim about what left the browser. Advanced if the priority is a number close to the truth across the whole audience. The choice belongs in writing, next to the banner, because the reports will be read by people who did not make it.

Can we skip the banner with a privacy-first analytics tool?

Sometimes, and only if the install meets the exemption conditions in full — truncated IP, 13-month lifetime, no cross-site joins, a working objection route. Marketing teams usually discover the tool cannot keep all of those promises while also feeding a CRM.

Share: tw in
Faraz Frank

About Faraz Frank

Author at WP Frank. Writing about WordPress development, design, and best practices.

View all posts by Faraz Frank →
edit_note

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.