AI SEO Tools Ranked
All posts
By AI SEO Tools Ranked TeamGA4AI trafficHow-toAnalytics

How to measure AI search traffic in GA4 (and what it can't see)

A step-by-step GA4 tutorial for isolating visits from ChatGPT, Perplexity, Gemini, Claude, and Copilot with a referral regex and a custom channel, plus the blind spots GA4 leaves and how to fill them.

What you can measure, and what you can't

When someone clicks a link in a ChatGPT or Perplexity answer, their browser usually passes the assistant's domain as the referrer. Google Analytics 4 records that like any other referral. So the basic job, counting visits from AI assistants, is a filtering exercise you can set up in an afternoon.

The harder part is what GA4 never sees. Some AI visits arrive with no referrer at all and land in "direct." Clicks from Google's AI Overviews and AI Mode arrive as ordinary Google organic traffic. And GA4 has no idea which prompt or citation sent the visitor. This tutorial covers the setup first, then the gaps, then how to close them.

We've kept the GA4 instructions generic on purpose. Google renames menus often, and the concepts below (session source, regex filters, custom channel groups, key events) are what matter.

Step 1: see what's already there

Start with your traffic acquisition report and switch the dimension to session source (or session source / medium). Search the list for assistant domains. You'll probably find some of these:

AssistantReferrer domain to look for
ChatGPTchatgpt.com (older visits: chat.openai.com)
Perplexityperplexity.ai
Geminigemini.google.com
Microsoft Copilotcopilot.microsoft.com
Claudeclaude.ai
DeepSeekchat.deepseek.com
Grokgrok.com
Meta AImeta.ai
Mistral Le Chatchat.mistral.ai

Check your own source list for others. New assistants appear, and some send traffic through subdomains you won't predict. Also note that ChatGPT often adds a utm_source=chatgpt.com parameter to links, so you may see it as a source value even where the referrer was stripped.

Step 2: build one regex for all AI sources

Rather than filtering domain by domain, write a single regular expression and reuse it everywhere:

.*(chatgpt\.com|chat\.openai\.com|perplexity\.ai|gemini\.google\.com|copilot\.microsoft\.com|claude\.ai|chat\.deepseek\.com|grok\.com|meta\.ai|chat\.mistral\.ai).*

The .* at each end makes it work whether a GA4 filter treats regex as a full match or a partial match. Escape every dot with a backslash; an unescaped dot matches any character, which can catch unrelated domains. Keep this regex in a shared doc, because you'll update it as new assistants show up.

Step 3: create an exploration for AI traffic

Open a blank exploration. Add session source and landing page as dimensions, and sessions, engaged sessions, and your key events as metrics. Then add a filter where session source matches the regex from step 2.

You now have a working view of which pages AI assistants send people to and what those visitors do. Sort by landing page and look for concentration. If a handful of guides, comparison pages, or pricing pages account for most AI visits, those are the pages worth protecting, and the first ones to check when the numbers dip.

Add a date comparison against the previous period. Month-over-month change is more useful than any single total.

Step 4: give AI assistants their own channel

Explorations are good for analysis but awkward for everyday reporting. A custom channel group fixes that. GA4 lets you define your own channel rules in its admin settings; create a copy of the default group and add a new channel called something like "AI assistants," with the rule "session source matches regex" and the regex from step 2.

Order matters. Channel rules are evaluated top to bottom, and the default Referral channel would otherwise claim these sessions first. Move your AI channel above Referral.

Once saved, the AI channel shows up in standard acquisition reports next to Organic Search, Paid, and the rest, which is where most stakeholders look.

Step 5: connect it to outcomes

Traffic alone rarely survives a budget meeting. Make sure the actions that matter are marked as key events (what GA4 used to call conversions): signups, demo requests, purchases, contact form submissions. Then report AI-assistant sessions and key events side by side, and compare the conversion rate against organic search.

That comparison often reframes the discussion. AI-referred visitors arrive after an assistant has already summarized options for them, so their behavior can differ from a cold organic visit. Whatever your numbers show, they're your numbers rather than an industry average.

The blind spots GA4 leaves

Set all that up and you'll have an honest undercount. Here's where the missing traffic goes.

Visits with no referrer. Clicks from some mobile apps, copy-pasted links, and certain privacy settings arrive without a referrer. GA4 files them as direct. You can't recover a referrer the browser never sent, and no tool can.

Google's own AI features. Clicks from AI Overviews and AI Mode arrive as google / organic. GA4 can't separate them from classic blue-link clicks.

Consent and blocking. Where visitors decline analytics cookies or block scripts, GA4 sees less. In regions with strict consent rules, that gap can be meaningful.

No link to the cause. GA4 tells you a session came from chatgpt.com. It can't tell you which prompt, which answer, or which citation produced it, so you can't tell which content work drove the change.

Crawls aren't visits. AI crawlers fetching your pages don't run GA4's tag, so GA4 has no record of whether ChatGPT, Claude, or Perplexity even read the pages you want cited.

Filling the gaps with Promptwatch

GA4 is fine as a sanity check. It wasn't built to measure AI search, and the gaps above are the ones that matter for decisions. This is the workflow we'd hand to Promptwatch.

Visitor analytics installs through a lightweight script or a GTM template, so if you already run Google Tag Manager the setup is one tag. It records AI-referred traffic and conversions and puts them in the same workspace as your prompt tracking and citation analytics. That's the missing link from the last blind spot: you can see that a page gained citations in Perplexity answers and, in the same place, whether Perplexity visits to that page rose and converted.

It won't conjure a referrer that a browser dropped. What it gives you is context to read those numbers against. When a page's citations climb and its direct traffic rises at the same time, that pattern is visible next to the citation trend instead of buried in a separate GA4 report.

For the crawl side, Agent Analytics reads AI crawler logs from your CDN (Cloudflare, AWS CloudFront, Fastly, Vercel, Netlify, Akamai, Google Cloud CDN, or a custom HTTP source) and shows which pages ChatGPTBot, ClaudeBot, PerplexityBot, GoogleOther, and the Meta AI crawler fetched. GA4 can't see any of that.

On plans: Essential ($95/mo) includes 200K visitor events. Professional ($245/mo) includes 1M visitor events and adds 25M crawler logs. Business ($579/mo) includes 10M visitor events. There's also a Google Search Console integration if you want classic search data in the same view.

Keep your GA4 channel running. It's free and it keeps your AI numbers visible in the reports your company already reads. Use Promptwatch for the questions GA4 can't answer: which prompts, which citations, which crawls, and what they were worth. For other analytics-focused tools, see the full ranking.

FAQ

Why does my AI traffic in GA4 look so small?

Partly because it's an undercount: referrer-less visits land in direct, and AI Overviews clicks land in organic. Partly because AI assistants answer many questions without sending a click at all.

Can GA4 track Google AI Overviews traffic separately?

Not on its own. Those clicks arrive as Google organic traffic.

Do I need to update the regex?

Yes, periodically. Check your session source list every month or so for new assistant domains and add them.