If your answer to "where did this lead come from?" is usually "no idea, GA4 says Direct," you are not alone. AI is clearly sending you visitors and customers — but learning to measure AI search traffic in GA4 is far harder than measuring classic SEO traffic, because most clicks from ChatGPT, Perplexity, Gemini, and Copilot dissolve into Direct or Referral in your GA4 reports. This article is not about visibility — we covered GEO and getting cited in a separate article. Here we focus on a single question: how do you isolate this AI-driven traffic inside GA4, measure it, and connect it to your CRM?
1. Why does AI traffic disappear in GA4?
The root of the problem is technical, and there isn't just one cause. Four separate mechanisms strip the referrer along the way, and each one hides a different slice of your AI traffic:
- In-app browsers: A user who taps a link inside the ChatGPT mobile app opens it in the app's own embedded browser. These browsers mechanically strip the referrer header. The user came from an AI recommendation, but GA4 sees a visit with no source.
- Copy-paste behaviour: When a user copies the URL from an AI answer and pastes it into a fresh tab, no referrer header is passed at all. This is especially common on desktop.
- Referrer-policy headers: chatgpt.com's
strict-originReferrer-Policy and therel="noreferrer"attribute on some outbound links deliberately hide the source. - Links without UTMs: The AI writes your URL into its answer itself. That link carries no UTM parameter, because you didn't put it there — you can't. With no source, GA4 files the visit under Direct.
The critical point: the engines don't behave alike. Perplexity and Google AI Mode generally pass a referrer, so they're relatively easy to catch in GA4. ChatGPT in-app clicks, on the other hand, mostly land as Direct. Across industry datasets, roughly 60–70% of confirmed AI visits arrive with no referrer signal at all. That's why your AI-traffic count in GA4 is always a lower bound on reality — you undercount, never overcount.
2. The AI referral domain dictionary you need to track
Before you build your channel group and regex, you need to know which source/referrer values to expect. As of 2026, these are the core AI domains you'll encounter in GA4 reports:
| Engine | Referrer / source value | Behaviour |
|---|---|---|
| ChatGPT | chatgpt.com, chat.openai.com | Usually Direct; sometimes a referrer on desktop web |
| Perplexity | perplexity.ai | Usually passes a referrer — easy to catch |
| Gemini / Google AI Mode | gemini.google.com | Usually passes a referrer |
| Copilot | copilot.microsoft.com, bing.com/chat | Variable; sometimes a referrer |
| Claude | claude.ai | Usually passes a referrer |
| You.com | you.com | Passes a referrer |
Let's be honest about one exception: separating clicks from Google AI Overviews (the AI summary at the top of the search results page) from organic traffic is next to impossible. The user still arrives via google.com, and GA4 classifies it as google / organic. You can't cleanly know how many clicks AI Overviews delivers — this is a genuine limit of the measurement, so accept it and move on.
3. Isolating AI traffic in GA4 with a custom channel group and regex
The cleanest method is to create a Custom Channel Group in GA4 and define a channel called "AI Assistants" using a regex on the source/referrer. The steps:
- Go to GA4 Admin > Channel groups and choose "Create new channel group" (starting from a copy of the default is the most practical route).
- Add a new channel named "AI Assistants".
- Set the condition to Source matches regex and enter the pattern below.
- Ordering is critical: GA4 evaluates rules top to bottom. Drag the "AI Assistants" channel above the Referral and Organic Search rows. Otherwise, sources like Perplexity get caught by Referral first and are misclassified.
Here's a clean regex that actually works. Note that the dot characters are escaped and subdomains ((.*\.)?) are allowed:
^(.*\.)?(chatgpt|openai|perplexity|gemini\.google|copilot\.microsoft|bing|claude|you)\.
This pattern catches chatgpt.com, chat.openai.com, www.perplexity.ai, gemini.google.com, copilot.microsoft.com, bing.com, claude.ai, and you.com. Note: bing is a broad match; if you don't want to sweep classic Bing organic search into the AI bucket, drop bing and keep only copilot\.microsoft. For an even cleaner split, pair this with the Session source dimension.
4. UTM strategy: tag what you can control
Regex is your only shot at catching links the AI writes itself. But there's also a second set — links you place with your own hands — and you can tag those with UTMs. This is the most reliable layer of the measurement, because the source information is embedded inside the link and survives even when the referrer is stripped.
Where you can add UTMs:
- Outbound links inside your llms.txt / docs / knowledge base — content that AI models read frequently.
- Your profile and directory listings (G2, Crunchbase, your LinkedIn company page, GitHub) — AIs cite from these.
- Your product documentation and support articles.
A simple schema: ?utm_source=chatgpt&utm_medium=ai_referral&utm_campaign=llms_txt. That way, everyone arriving via this link is attributed to the right source, even if their referrer was stripped.
An honest limit: you can't tag a link that lives inside text the AI generates freely. If ChatGPT says "check out this company" and shows your homepage, that URL is not under your control and carries no UTM. This is exactly the gap the regex in step 3 closes. The two methods complement each other: UTM is precise but narrow, regex is broad but noisy.
5. Building the report: GA4 Exploration or Looker Studio
Once the channel group and UTMs are in place, you need to make the measurement visible. There are two practical routes:
GA4 Exploration (free, fast)
Create a free-form exploration and define a segment: Session source matching the regex above. Then slice that segment with these dimensions and metrics:
- Dimensions: Session source / medium, Landing page, Device category, Country
- Metrics: Sessions, Engaged sessions, Engagement rate, Key events (conversions), Session key event rate
Looker Studio (shareable dashboard)
To show leadership and sales, connect GA4 to Looker Studio. Pin the "AI Assistants" channel as a filter; on a single screen, show the weekly trend of AI sessions as a time series, the per-engine breakdown, and the conversion rate. When you build this kind of measurement architecture, keeping the methodology within the same framework as our SEO data analysis approach ensures the data stays comparable with your other channels.
6. Connecting the lead source to your CRM — this is the real part
Seeing AI traffic in GA4 is nice, but sales doesn't look at GA4. Sales looks at the CRM. For a rep to see that a lead came from ChatGPT, you need to carry the source into the form and from there into the CRM. The logic goes like this:
- Capture on first touch: When the visitor first arrives, a small piece of JavaScript reads the UTM parameters and the
document.referrervalue and writes them to a cookie as "first-touch." That way, even if the user browses around and converts days later, the original source isn't lost. - Hidden form field: When the form is submitted, that cookie value is populated into a hidden input.
<input type="hidden" name="lead_source" value="ai:chatgpt">
<input type="hidden" name="first_touch_referrer" value="chatgpt.com">
<input type="hidden" name="last_touch_medium" value="ai_referral">
- Map to a CRM field: Your form writes this value into a "Lead Source" field in the CRM. Now, when a rep opens the record, they see
lead_source = ai:chatgptand can frame the conversation accordingly.
For the cases where the referrer is stripped, add a second layer: server-side measurement. If you send the lead event from your server via the GA4 Measurement Protocol or server-side GTM and match it by client_id, you complete the data even when browser signals are weak. This is also the foundation of the Conversion API infrastructure that feeds conversions back to ad platforms. If you want to unify first-touch/last-touch source across all channels into a single customer profile, the right home for the job is a CDP — source data is normalized there, and you can trigger marketing automations based on an "AI-sourced lead" segment.
7. Which KPIs should you watch?
Once you're measuring AI traffic, the numbers you track differ from classic traffic volume — the volume is small but the intent is high:
- AI-referral sessions: Total and broken down by engine. The trend direction matters more than the absolute number.
- Assisted conversions: Journeys where AI was the first touch but the conversion closed on another channel.
- Branded-search lift: As AI visibility grows, searches for your brand name on Google rise. Track it in Search Console — it's indirect but strong evidence of AI impact.
- Lead-to-source attribution: The share of AI-sourced leads in the CRM and — most importantly — their close rate. Visitors from AI typically convert far above average, because they were already looking for an answer and got pointed to you.
8. Honest limits
Let's be clear about what this system can and can't do, because overblown promises undermine measurement:
- You measure the click, not the impression. GA4 can't tell you how many times your brand was named in a ChatGPT answer; it only sees whoever clicked through from that answer to your site. Measuring visibility inside AI (share of voice) is a separate job and belongs on the GEO side.
- Attribution is directional, not flawless. Clicks with a stripped referrer keep landing in Direct; your count sits below reality. You read the trend and relative growth correctly, not the absolute figure.
- AI Overviews can't be separated out. You can't cleanly split Google organic from AI-summary clicks.
These limits don't make the system worthless — on the contrary, they move you from "I have no idea" to "I have a high-intent channel steered by AI, and it's growing." You can't manage this channel without setting up the measurement. As you prepare this infrastructure for 2026, our SEO and GEO readiness checklist lays out which pieces to build first.
Summary and next step
Measuring AI search traffic has four layers: (1) isolating AI sessions with a custom channel group + regex, (2) UTMs on the links you control, (3) a GA4 Exploration or Looker Studio report, (4) carrying the first-touch source into your CRM via a hidden form field. Built together, your sales team sees that a lead came from ChatGPT, and marketing reports this channel's real contribution.
Partnerfy builds exactly this: GA4 channel architecture, unified customer source via a CDP, server-side measurement with the Conversion API, and GEO visibility tracking. If you want to lift your AI traffic out of the Direct bucket and turn it into a real channel, book a meeting or get in touch — we'll look at your current GA4 and CRM setup and figure out where to start together.