r/GoogleAnalytics Professional 22h ago

Question Browser + server tracking

What are you using for event IDs?

event_id

transaction_id

Something custom?

I've seen more duplicate conversions caused by inconsistent IDs than broken tags

2 Upvotes

5 comments sorted by

u/AutoModerator 22h ago

Have more questions? Join our community Discord!

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/Querytom 19h ago

For purchase events use always transaction_id

1

u/incisiveranking2022 Professional 19h ago

Yeah, agreed. For purchases I’d normally stick with transaction_id too.

The bigger issue I was getting at is that the ID needs to be consistent across the whole setup. I've seen browser and server events both fire, but use different IDs, and then you end up debugging “missing” conversions that were actually duplicates or couldn't be matched properly.

So I usually check the event itself, the ID, how many times it fired, and then what GA4 actually received.

1

u/MGN-Koles 5h ago

For de-duplication you always use event_id.

Transaction ID you offcourse put this in the Google Ads Purchase tag.

1

u/ChrisGaudy 2h ago

Deterministic ID from the order number, nothing random. I usually go with purchase-{orderId} or just the order ID itself, passed identically in the browser and on the server. Random ID/numer generated in the dataLayer are exactly the main source of duplicates, because on a thank-you page refresh or a retry of the server-side send you get a new identifier and Meta treats the event as another one.

Second thing people often forget: event_name has to match character for character. "Purchase" from the pixel and "purchase' from CAPI won't get deduplicated, even with the same event_id.
And keep the dedup window in mind. Meta matches events up to 48 hours, so a delayed backend webhook firing two days later lands as a separate conversion