Attribution in GA4: 3 Key Elements to Watch
The arrival of Google Analytics 4 (GA4) has reshaped how attribution works. Along with new possibilities, it also brings challenges for marketers. Think, for instance, of the mysterious "(not set)" and "(data not available)" labels showing up in reports, Google Ads clicks that don’t get tracked, or strange traffic sources that seem to appear out of nowhere.
In this article, we look at three common attribution challenges in GA4 and show you how to identify and work around them so you can base your decisions on reliable marketing data.
1. The "(not set)" and "(data not available)" labels
These labels in GA4 reports both indicate missing information, but for very different reasons.
Quelques bonnes pratiques à adopter
- The "(not set)" label means GA4 was expecting a value but never received it. This is usually due to a configuration issue. For example, it can happen if your Google Ads account isn’t linked to GA4 or if auto-tagging is turned off. In short, GA4 shows "(not set" when it has no data to display.
- The more recent "(data not available)" label appears when the data simply isn’t ready yet and is still being processed. This is common with very recent or real-time data. In most cases, waiting 24 to 48 hours is enough for the data to appear correctly.
To sum it up: "(not set)" typically signals a technical issue on your end, while "(data not available)" usually means the data is still being processed by Google. If you see "(not set)" in your GA4 reports, it’s worth investigating, as it often points to a problem in your tracking setup.
2. Auto-tagging and the pitfalls of the Google Click Identifier (GCLID)
The Google Click Identifier (GCLID) is a unique parameter added to a URL when someone clicks on a Google ad. It allows GA4 to assign the session to the correct campaign. However, several technical factors can interfere with this process:
- Unlinked accounts: GA4 won’t recognize the GCLID if your GA4 property isn’t connected to your Google Ads account.
- Auto-tagging disabled: Without auto-tagging, GA4 can’t link sessions to campaigns because the GCLID is never applied.
- GCLID lost during a redirect: If users are redirected to another page after clicking the ad (for example, via a link shortener or a server-side redirect), the GCLID can be stripped before GA4 can capture it.
- Incomplete manual UTM tags: If you’re not using auto-tagging, you need to provide at least the utm_source, utm_medium, and utm_campaign parameters manually.
- GA4 tag fires too late: Your GA4 tag may miss the GCLID entirely if it triggers only after the page loads or after the user gives consent. In this case, the session may go untracked or be classified as "direct traffic.
5 important questions to help avoid attribution errors:
- "Is my GA4 property properly linked to Google Ads?"
- "Is auto-tagging enabled in Google Ads?"
- "Is the GCLID preserved during redirects?"
- "Are my UTM tags present, complete, and consistent?"
- "Does my GA4 tag fire as soon as the page loads?"
3. Misattribution in single-page applications (SPAs)
Single-page applications (SPAs) don’t trigger a full page reload when users move from one section to another, which can confuse GA4. Only the content changes while the page technically stays the same. GA4 may then treat this as a new session and attribute it to the wrong source.
Here’s a typical scenario:
- A user clicks a Google ad. The GCLID is passed to GA4, and the session is correctly attributed to the campaign.
- The user clicks an internal link to view a product page. Since it’s a SPA, there’s no full reload.
- GA4 sees a new page view but doesn’t realize it’s part of the same session.
- The GCLID is no longer in the URL, and the context hasn’t been preserved.
- GA4 assumes it’s a new session and tries to assign a new source, often defaulting to the last known referrer (like google.com).
The result? The session is wrongly classified as organic traffic, even though the user came from a paid ad.
How to prevent this issue
Voici trois solutions pour vous aider!
- Notify GA4 of every URL change: Since SPAs don’t trigger full reloads, GA4 won’t detect new page views automatically. Use a “History Change” trigger in Google Tag Manager to send a signal when the URL changes.
- Preserve the GCLID and session context: Make sure redirects, URL changes, or browser history changes don’t strip tracking parameters or reset attribution cookies. The GCLID should still be in the URL when the GA4 tag fires. Test your navigation flows to confirm this.
- Set up referral exclusions: External services like Stripe or PayPal can mistakenly be treated as referrers when users return to your site. Add these domains to your referral exclusion list in GA4 to avoid skewed attribution.
Practical tips for better attribution in GA4
- Wait for data to stabilize before analyzing reports: Some data in GA4 can take up to 48 hours to be fully processed.
- Review "(not set)" labels carefully: They often indicate missing or broken tags.
- Check Google Ads integration: Make sure your accounts are linked, auto-tagging is on, and UTM parameters are consistent.
- Test GCLID retention: Add ?gclid=Test123 to a URL and verify that it stays in the address bar after the page loads.
- Always use complete and standardized UTM tags: Include at least utm_source, utm_medium, and utm_campaign for reliable attribution.
- Watch for unusually high direct traffic: This may indicate a problem with your tagging or setup.
- Adjust SPA tracking: Make sure GA4 receives the correct signals when users navigate through your app.
- Keep up with GA4 updates: Regularly check release notes and documentation so you can adapt as the platform evolves.
Get the most out of your attribution in GA4
GA4’s attribution system can seem complex, but it’s entirely manageable. By avoiding tagging mistakes, ensuring key parameters like the GCLID are preserved, and adapting your setup to the specific nature of your site—whether it’s single-page or not—you’ll gain more reliable data to measure the impact of your marketing efforts. Our data science team can also help you get there.
Get in touch to tell us about your project and make confident, data-driven decisions.