Connecting CookieYes to GA4
CookieYes serves smaller sites that adopted a consent banner because a plugin suggested it, which frequently means the banner is stricter than the business's legal position requires. GA4 is where the business goes to understand what happened, which makes an unattributed conversion there expensive in decisions rather than in ad spend. The join between them succeeds or fails on one thing: whether the GA4 client_id reaches the CookieYes consent record before the conversion happens, because GA4 can only match a conversion it can tie back to a click it recognizes.
Free30 minutesNo obligation
Specific to this pair
CookieYes and GA4: consent mode without losing your sessions
Configure CookieYes's Consent Mode v2 so it loads before the GA4 tag and sets defaults per region. For server-side purchases via Measurement Protocol, a client_id exists only if analytics_storage was granted and _ga was written; without it a purchase becomes an orphan user. Pass the consent object with ad_user_data and ad_personalization, and check whether US opt-out rules apply instead.
CookieYes supports Google Consent Mode v2, so for GA4 the question is mostly configuration: whether the banner loads before the GA4 tag, whether default states are set per region, and whether analytics_storage is denied for visitors in markets that do not require it. A US-only store running CookieYes with a global default-deny is choosing to lose sessions, and GA4 shows it as a drop in users and a rise in unassigned or direct traffic rather than as an obvious error.
For server-side purchase events via Measurement Protocol, a client_id only exists if analytics_storage was granted and the _ga cookie was written. For visitors who denied it there is no client_id to send, and sending the purchase anyway creates an orphan user with no source. Send those purchases only if your legal position allows it and accept they carry no attribution; check whether your Measurement Protocol calls pass the consent object with the visitor's ad_user_data and ad_personalization state.
Check whether CookieYes is set up for US opt-out laws such as CCPA/CPRA, with a Do Not Sell or Share link and Global Privacy Control handling, rather than an EU-style opt-in banner. Under an opt-out model analytics may be able to run by default, which changes your GA4 numbers more than any tagging fix will.
CookieYes → GA4 · what breaks
Why this join usually fails — CookieYes → GA4
- 01
The GA4 client_id never reaches CookieYes
Default configurations frequently block before consent, so identifier capture is lost on the first page for every visitor.
- 02
A banner stricter than the law requires
Plugins default to the strictest setting because that is safest for the plugin vendor. For a business whose customers are all in a market with different rules, that default costs a large share of measurable conversions and buys no protection that was needed.
- 03
Everything lands under (direct)/(none)
The classic Measurement Protocol symptom, and it always means the same thing: the client_id was missing or wrong, so GA4 had no session to attach the event to and invented a new user.
- 04
Nothing reconciles afterwards
GA4 DebugView shows events arriving with their parameters, and Realtime confirms the user and session they attached to. Neither tells you whether you are double-counting — for that, compare GA4's conversion count against the source system's record for the same window.
CookieYes → GA4 · the fix
What working looks like — CookieYes → GA4
The GA4 client_id on every consent record
Conversions arriving in GA4
Conversions appear in GA4 attributed to the original session's source and medium, so acquisition reporting reflects what actually drove revenue.
Reconciled against the source
CookieYes → GA4 · architecture
How CookieYes and GA4 actually connect
- 1
CookieYes holds the truth
For a small business the practical question is often whether the banner configuration matches the obligation. A default-deny banner in a market with no such requirement is data thrown away for nothing.
- 2
GA4 needs a click to match
GA4 needs the client_id to attach a server event to the user and session that produced the click. Without it there is no attribution to inherit and the event is orphaned.
- 3
The identifier is the bridge
The GA4 client_id, captured at the visit and carried into the CookieYes consent record.
- 4
The event source decides reliability
Send consented conversions with the consent rate stated.
- 5
Deduplication at the destination
GA4 has no built-in deduplication for Measurement Protocol. If the browser also sends the event, it counts twice. The only reliable approach is to decide per event which side sends it, and enforce that decision — GA4 will not protect you from your own duplicates.
CookieYes → GA4 · normal or broken
Working vs. broken, side by side — CookieYes → GA4
Normal, not a fault
The GA4 client_id present on the consent record
Sent from your order system, gated on consent
Deduplicated correctly
GA4 has no built-in deduplication for Measurement Protocol. If the browser also sends the event, it counts twice. The only reliable approach is to decide per event which side sends it, and enforce that decision — GA4 will not protect you from your own duplicates.
Reconciles with the source
Actually broken
The GA4 client_id missing on most records
Default configurations frequently block before consent, so identifier capture is lost on the first page for every visitor.
Sent from the browser
Plugins default to the strictest setting because that is safest for the plugin vendor. For a business whose customers are all in a market with different rules, that default costs a large share of measurable conversions and buys no protection that was needed.
Counted twice, or not at all
The classic Measurement Protocol symptom, and it always means the same thing: the client_id was missing or wrong, so GA4 had no session to attach the event to and invented a new user.
Nobody has reconciled it
CookieYes → GA4 · diagnose
Diagnostic order — CookieYes → GA4
- 01
Count consent records carrying the GA4 client_id
- 02
Follow one real conversion end to end
- 03
Confirm which regulations actually apply to your customer base
A legal question, not a technical one, and worth answering before accepting a default that costs you a third of your data.
- 04
Check whether server events carry a session and a source
In GA4 Realtime or DebugView, find the event and look at its session and traffic source. A brand-new user with no source on every server event is the missing-client_id signature.
- 05
Read the match rate, not the success message
GA4 DebugView shows events arriving with their parameters, and Realtime confirms the user and session they attached to. Neither tells you whether you are double-counting — for that, compare GA4's conversion count against the source system's record for the same window.
CookieYes → GA4 · prove
How it gets proven — CookieYes → GA4
Source of truth
Your order system, with consent state attached to the event.
- The GA4 client_id confirmed present on a live consent record.
- Server events confirmed in DebugView attaching to an existing session with the original traffic source intact.
- Consented conversions reconciled against imported figures, with the configuration checked against the obligation.
CookieYes → GA4 · free audit
What we check in the free audit
- Count consent records carrying the GA4 client_id
- Follow one real conversion end to end
- Confirm which regulations actually apply to your customer base
- Check whether server events carry a session and a source
- Read the match rate, not the success message
Checked against
Your order system, with consent state attached to the event.
Free30 minutesNo obligation
CookieYes → GA4 · when not to buy
When you don't need this — CookieYes → GA4
- Measure identifier coverage yourself first — pull your last hundred consent records and count how many carry the GA4 client_id.
- This is the common case for small sites: get the legal position confirmed first. The right banner may be considerably lighter than the one installed.
- GA4 is reporting, not bidding. If your problem is ad platform optimization, fix the ad platform destination first — GA4 will not change what any campaign does.
CookieYes → GA4 · what we deliver
What gets built — CookieYes → GA4
Identifier capture into CookieYes
Check the default blocking behaviour against your actual legal obligation, then capture accordingly.
Event source: your order system, gated on consent
Send consented conversions with the consent rate stated.
Dispatch to GA4
Measurement Protocol events with the client_id, session_id and the correct measurement ID and API secret, sent server-side.
Reversals where they exist
Withdrawal stops future sends.
Written guarantee
95%+ tracking accuracy
Measured against Your order system, with consent state attached to the event.. Miss it and we keep working at no cost.
From $400 · See packages
FAQ
CookieYes → GA4 questions, answered
CookieYes supports Google Consent Mode v2. Check that it loads before your GA4 tag and that default consent states are set per region rather than one global default-deny.
Most often the banner denies analytics_storage by default for every visitor, including regions where that is not required. Compare the region settings against where your customers actually are.
Almost always because the GA4 client_id never reached the CookieYes consent record. Default configurations frequently block before consent, so identifier capture is lost on the first page for every visitor. Measure coverage before debugging the dispatch.
The client_id, from the _ga cookie. Measurement Protocol events without it are rejected or create a brand-new user with no session and no source, which is how server events end up filed under (direct)/(none) and make paid channels look worse than they are. Send session_id alongside it so the event joins the existing session, and include engagement_time_msec or the event may not appear as expected in reports.
Your order system, gated on consent. Send consented conversions with the consent rate stated.
GA4 DebugView shows events arriving with their parameters, and Realtime confirms the user and session they attached to. Neither tells you whether you are double-counting — for that, compare GA4's conversion count against the source system's record for the same window.
More on CookieYes → GA4
- Stripe → GA4Connecting Stripe to GA4
- PayPal → GA4Connecting PayPal to GA4
- HubSpot → GA4Connecting HubSpot to GA4
RELATED GUIDES
Where CookieYes → GA4 fits in the rest of your tracking
- Complianz → GA4Connecting Complianz to GA4
- Usercentrics → GA4Connecting Usercentrics to GA4
- Cookiebot → GA4Connecting Cookiebot to GA4
- CookieYes → MixpanelConnecting CookieYes to Mixpanel
- CookieYes → PostHogConnecting CookieYes to PostHog
- Financial servicesConversion tracking for financial services, built for the compliance review
- iubenda → GA4Connecting iubenda to GA4
- Termly → GA4Connecting Termly to GA4
Free · 30 min
Get CookieYes and GA4 joined properly
Free30 minutesNo obligation
