Tracking AI Mode Traffic in GA4: A Setup Guide
GA4 doesn't have a built-in "AI Mode" traffic source. AI-originated visits land in GA4 the same way regular Google search traffic does. Usually as Organic Search. Sometimes as Referral. Sometimes as Direct, depending on browser and OS.
To separate AI Mode and AI Overview traffic from regular Google search traffic, you have to configure GA4 yourself with filters, custom dimensions, and saved explorations. This post is the step-by-step setup Brass-SEO uses to track AI traffic in GA4 as of May 2026.
The setup takes about 30 minutes and gives you ongoing visibility into AI-originated traffic without waiting for Google to publish a native report. The method may need updates as Google changes referrer behavior. Check back quarterly.
Quick Navigation
- Why GA4 Doesn't Surface AI Traffic by Default
- The Three Referrer Patterns to Capture
- Step 1: Create a Custom Dimension for Referrer Hostname
- Step 2: Set Up a Segment for AI Traffic
- Step 3: Build an Exploration Report
- Step 4: Cross-Reference with GSC Impression Data
- Limitations and What This Doesn't Catch
- Frequently Asked Questions
Why GA4 Doesn't Surface AI Traffic by Default
GA4 assigns traffic sources based on the document.referrer value and the UTM parameters in the URL when a user lands on your site. As of May 2026, traffic that originates from a Google AI Mode response is most often classified as Organic Search with google as the source. Identical to a regular Google search click. There's no first-party Google referrer field that says "this came from AI Mode."
The cause is technical. AI Mode and AI Overviews render inside the Google Search environment. The cited links use the same referrer machinery as other Search results. Some browsers further strip or modify referrer information for privacy, removing the path detail that might otherwise reveal the AI surface.
A few referrer variations do exist and are worth capturing:
vertexaisearch.cloud.google.comand related Google AI domains for some experimental surfacesgoogleweblight.comand similar lite-mode domains- Third-party AI engines like
chat.openai.com,perplexity.ai,claude.ai, andgemini.google.comwhen users click through from those engines directly
These are the patterns worth filtering on, even though they don't cover all AI traffic. They capture the most identifiable share.
The Three Referrer Patterns to Capture
Brass-SEO's recommended filter set covers three referrer pattern groups.
1. Direct AI engine referrers. Hostnames containing chat.openai, perplexity, claude.ai, gemini.google.com, copilot.microsoft.com, and similar branded AI domains. These are unambiguous. A click from one of these is an AI-originated visit.
2. Google AI experimental subdomains. Hostnames like vertexaisearch.cloud.google.com and other Google subdomains that occasionally appear in AI Mode and AI Overview citation links.
3. Generic Google referrers with AI-suggesting paths or parameters. This is the loosest category and the hardest to filter on. Most AI Mode traffic appears as standard google.com referrers. Some URL parameters Google appends in certain AI contexts can be filterable. The pattern shifts often enough that Brass-SEO recommends not relying on it as the primary signal.
The first two filter groups capture the clearly-identifiable AI traffic. The third group is supplementary and requires periodic adjustment.
Step 1: Create a Custom Dimension for Referrer Hostname
GA4 captures page_referrer as an event parameter on page_view events but doesn't expose it directly in reports. To use it for filtering, register it as a custom dimension.
- In GA4, go to Admin → Custom definitions → Create custom dimensions
- Dimension name:
Page Referrer - Scope: Event
- Event parameter:
page_referrer - Save
GA4 will start populating the dimension from the next event onward. Historical data isn't backfilled. Only events captured after dimension creation will have the dimension available for reports.
If you have engineering capacity, a cleaner alternative is to add a custom referrer_hostname event parameter to your GA4 events that parses the hostname out of the referrer URL on the client side. This produces cleaner data than filtering on the full URL.
Step 2: Set Up a Segment for AI Traffic
In GA4, segments isolate traffic that matches a condition.
- Navigate to Explore and create a new exploration
- In the left panel, click + Segments → Create custom segment
- Segment name:
AI Originated Traffic - Conditions: Page Referrer contains
chat.openai.comOR Page Referrer containsperplexity.aiOR Page Referrer containsclaude.aiOR Page Referrer containsgemini.google.comOR Page Referrer containsvertexaisearchOR Page Referrer containscopilot.microsoft.com - Save
This segment will isolate the clearly-AI-originated traffic. Apply it to any exploration to see only AI-sourced sessions, pages, conversions.
Step 3: Build an Exploration Report
With the segment in place, build an exploration that compares AI-originated traffic to total organic traffic.
- Technique: Free-form
- Dimensions: Landing Page, Session source / medium, Page Referrer
- Metrics: Sessions, Engaged sessions, Event count, Conversions
- Segments applied:
AI Originated TrafficandAll Users(compare side by side)
The result is a table showing which landing pages receive AI-originated traffic, how engaged that traffic is, and which AI engine sent it. Save the exploration so you can revisit it monthly without rebuilding.
A useful follow-up exploration: filter by Landing Page for specific high-impression pages from your GSC top pages list. This tells you whether your most-trafficked pages are also receiving AI-originated visits, or whether AI traffic is concentrating on different pages than traditional organic.
For the broader question of how to interpret GA4 traffic source data, see Where Is My Traffic Coming From? A GA4 Guide and The Only 5 GA4 Numbers That Matter for Your Business.
Step 4: Cross-Reference with GSC Impression Data
The hardest-to-attribute AI traffic — Google AI Mode citations that arrive as standard google.com referrers — can be approximated by cross-referencing GSC impressions against GA4 sessions.
When Google AI surfaces cite a page, the page typically gains GSC impressions without proportional GSC clicks. Some users get their answer from the AI summary. When GSC impressions are rising while GA4 organic sessions for the same page are flat or declining, the gap is likely AI surface visibility that's earning impressions but not clicks.
The method:
- In GSC, pull Page-level performance for the top 20 pages over the last 28 days vs. the prior 28 days
- In GA4, pull session counts for the same pages over the same windows
- Calculate the impression growth and session change per page
- Pages with significant impression growth and flat/declining sessions are likely AI-surface affected
Not perfect attribution. The most reliable signal of AI surface presence without a native GSC AI Mode report.
For more on the GSC impression/click divergence pattern, see How to Read GSC's Search Appearance Report and Why GSC Data Is 2-3 Days Behind.
Limitations and What This Doesn't Catch
The referrer-based method has gaps worth knowing about.
Direct traffic that originated from AI engines. When a user copy-pastes a URL from a ChatGPT or Perplexity response and visits it in a fresh tab, the visit lands as Direct, not Referral. There's no way to attribute these to AI.
Mobile app traffic. ChatGPT, Perplexity, and Gemini have mobile apps where clicked links sometimes lose referrer data on the way to your site. iOS and Android browsers also handle referrer differently.
Privacy browser modes. Safari's Intelligent Tracking Prevention, Firefox's Enhanced Tracking Protection, and similar features can strip referrer data even when the source is identifiable.
AI Mode without explicit subdomain. Most AI Mode citations land with standard google.com referrers. Indistinguishable from regular search. The cross-reference approach in Step 4 is the best workaround.
The overall capture rate using this method is partial. Brass-SEO estimates 30–60% of AI-originated traffic is correctly attributed, depending on browser mix. The remainder shows up in Organic Search or Direct buckets. Until Google adds first-party AI surface attribution, this is the working baseline.
For the broader Brass-SEO approach to reading and interpreting your GA4 data, see the GA4 guide. To get conversational answers about your GA4 traffic patterns, start a Brass-SEO trial.
For the parallel GA4 setup that tracks Preferred Sources button clicks and the related CTR shifts, see How to Track Preferred Sources Conversions in GA4.
Frequently Asked Questions
Why doesn't GA4 have a built-in AI traffic report?
GA4's classification depends on the referrer Google sends, which conflates AI Mode clicks with regular search clicks. Google hasn't committed to surfacing AI-specific attribution to publishers as of May 2026. The community workarounds in this post are necessary precisely because the native data isn't there.
Will Google add native AI Mode reporting to GA4 or GSC?
Possibly. Uncertain. Google has added incremental AI-related fields to Search Console (such as Search Appearance entries for some AI features) but hasn't announced AI Mode-specific attribution. The realistic expectation is that GSC will eventually add a Search Appearance category for AI Mode, and GA4 will follow with source labeling. Timing is open.
How accurate is the referrer-based method?
Partial. The method catches the most identifiable AI traffic (clear third-party AI engines, some Google AI subdomains) and misses the bulk of Google AI Mode traffic that arrives as standard google.com referrers. Combined with the GSC cross-reference in Step 4, accuracy is workable for trend tracking. Not for exact attribution.
Should I use UTM parameters to track AI traffic?
You can't add UTMs to AI-originated clicks unless you control the source. You don't, for ChatGPT, Perplexity, etc. UTMs are useful for marketing campaigns you own. Not for ambient AI search traffic.
Are there third-party tools that solve this better?
Several commercial tools claim AI traffic attribution. As of 2026, most rely on the same referrer-based heuristics this post describes plus periodic checks against known AI citation lists. They can save setup time. They don't fundamentally solve the attribution gap. Manual quarterly testing (see How to Test Your Brand's AI Search Visibility) remains complementary to any automated tooling.