
Join 3,200+ other professionals and receive a monthly newsletter packed with GA4 & BigQuery news, tips & tricks
Already have an account? Sign inOne of the most annoying bugs in GA4 (at least for users of the GA4 data export) is the incorrect attribution of event traffic data. The issue occurs when a page view event is generated from a Google search ad and the event includes a gclid
parameter in the page url, but the event is still attributed to organic or direct traffic.
As long as you stick to the default traffic_source
fields (first user source, medium and campaign) then the traffic source information is correct. But when you query event or session level traffic acquisition fields, like channel grouping, source, medium and campaign, the misattribution will heavily affect your results.
Example: before and after
For example, compare these two results above. You see the result of two queries against a GA4 property that contains Google Ads traffic (using autotagging). Before the fix none of the sessions with a gclid
in the page_location
were attributed to paid search. After the fix we can conclude that in this specific case 33% of all sessions (!) should in fact be attributed to google / cpc
.
This percentage will differ in each data set, but based on various reports a misattribution of 10-30% of all sessions is no exception.
Although this bug is known for quite a while now, unfortunately Google didn't put any effort in fixing it. Let's see what we can do ourselves then.
In this tutorial I will show you how to create a workaround, so your session based traffic source acquisition queries for the following dimensions are spot on again:
- source / medium
- campaign
- default channel grouping
The same logic can also be applied other (event based) dimensions.