All Articles
    Technical
    Published July 20, 20268 min read

    AI Traffic Analytics: How to Track AI Referrals in GA4

    ChatGPT and Perplexity send you visitors, but almost nobody has the reporting set up to prove it. The hostnames, the GA4 build, and the honest limits.

    Matiss Katanenko

    Matiss Katanenko

    Co-founder, Honeyb

    AI Traffic Analytics: How to Track AI Referrals in GA4

    AI traffic analytics means isolating the visits that arrive from AI assistants, which land in your analytics as referrals from hostnames like chatgpt.com, perplexity.ai and gemini.google.com. In GA4 you can now read most of it through the native AI Assistant channel that Google added to the default channel group in May 2026, and capture the rest with a custom channel group built on a referrer-hostname regex. The catch worth knowing before you start: referral analytics only measures the slice of AI discovery that produces a click, and that slice is smaller than most teams assume.

    Which hostnames do AI assistants send traffic from?

    Every assistant that links out sets a referrer, and each has its own hostname or two. Some carry legacy hostnames from a rebrand that are still live for a subset of users, which is the usual reason a regex that looks complete still misses traffic.

    The table below lists the hostnames verified against vendor documentation and current tracking guidance on 20 July 2026. Reliability refers to desktop web sessions, where the referrer header survives. Mobile app sessions are a separate problem covered in the next section.

    AssistantReferrer hostname(s)Referrer reliably passed
    ChatGPTchatgpt.com, chat.openai.comYes on desktop web, no from the mobile app
    Google Geminigemini.google.com, bard.google.comYes on desktop web
    Perplexityperplexity.ai, www.perplexity.aiYes on desktop web, no from the mobile app
    Claudeclaude.aiYes on desktop web, no from the mobile app
    Microsoft Copilotcopilot.microsoft.comYes on desktop web
    DeepSeekdeepseek.comYes on desktop web
    Grokgrok.com, x.aiYes on desktop web
    Meta AImeta.aiInconsistent, mostly in-app
    You.comyou.comYes on desktop web
    Poepoe.comYes on desktop web

    Two hostnames on that list are worth flagging. `chat.openai.com` predates the ChatGPT rebrand and still appears in logs, so a regex anchored only to `chatgpt.com` undercounts. `bard.google.com` is the same story for Gemini. Neither is large, but both are free to include.

    Why does so much AI traffic show up as Direct?

    Because the referrer never arrives. Three mechanisms cause it, and they are worth separating because only one of them is fixable at your end.

    The first is mobile apps. When someone taps a link inside the ChatGPT, Claude or Perplexity iOS or Android app, the session usually opens in an in-app browser with no referrer header. GA4 has nothing to categorise, so it files the visit under Direct. Given how much assistant usage is mobile, this is the largest single leak and you cannot close it from your side.

    The second is copy and paste. A meaningful share of assistant answers give a brand name and a URL as plain text rather than a clickable citation. The user types or pastes it. That is a genuine AI-driven visit with no referrer attached, and it is indistinguishable from someone typing your domain from memory.

    The third is your own tagging. If you have a stale custom channel group, or a session-scoped attribution setting that overwrites the referrer, correctly referred AI traffic can still land in the wrong bucket. That one is fixable, and the setup below is how.

    How do you set up AI traffic reporting in GA4?

    Start with what Google now gives you. On 13 May 2026 Google added an AI Assistant channel to the GA4 default channel group. Its definition is that the medium exactly matches `ai-assistant`, or the referrer matches Google's internal list of AI assistants, which the support documentation describes as sources like ChatGPT, Gemini, DeepSeek, Copilot and Grok (Google Analytics Help, accessed 20 July 2026).

    Note who is absent from that named list: Perplexity and Claude. If those matter to you, and for most B2B sites Perplexity does, the native channel alone will undercount. Build the custom group as well.

    Step 1. Create the custom channel group. Go to Admin, then Data display, then Channel groups. Click Create new channel group. Name it `AI Traffic` so it is obvious in reports next to the default group.

    Step 2. Add the AI rule. Click Add new channel. Name the channel `AI Assistants`. Set the condition to Source, match type `matches regex`, and use a pattern covering the hostnames from the table above. Anchor it so partial matches do not leak in.

    Step 3. Order the rule above Referral. This is the step people miss. GA4 evaluates channel rules top down and assigns on first match. If your AI Assistants channel sits below Referral, every AI visit is claimed by Referral first and your new channel stays empty. Drag it to the top of the list.

    Step 4. Build an exploration to see landing pages. Reports, then Explore, then Blank. Set the technique to Free form. Add `Session source` and `Landing page + query string` as dimensions, and `Sessions`, `Engaged sessions` and your key conversion as metrics. Add a segment: Session source matches regex, same pattern as above. Name the exploration `AI referral landing pages`.

    That last view is the one that pays for itself. It tells you which specific pages assistants are sending people to, which is the only reliable signal about which of your pages the models are actually reading and citing. Pair it with an AI visibility audit to check whether those pages match the questions you want to be recommended for.

    Want to see this in action?

    See how every major AI model talks about your brand. Free to start.

    Free AI Check

    Step 5. Set a review reminder. New assistants launch and old hostnames get retired. A regex written in July is stale by autumn. Diarise a quarterly check.

    What can each measurement approach actually tell you?

    No single source answers the whole question. Server logs, GA4 and answer-share monitoring measure three different stages of the same funnel, and confusing them is how teams end up with confident but wrong conclusions.

    QuestionServer logsGA4 referralsAnswer-share monitoring
    Are AI crawlers reaching my pagesYes, directlyNoNo
    Which pages get crawled mostYesNoNo
    Did a human click through from an assistantPartly, referrer in logYes, best sourceNo
    What did that visitor do on siteNoYesNo
    Does the assistant name my brand in answersNoNoYes, only source
    Which competitors are named alongside meNoNoYes
    Which sources the answer citedNoNoYes
    Captures no-click discoveryNoNoYes
    Works when referrer is strippedPartlyNoYes, unaffected

    Read down the last column and the gap becomes obvious. Everything about whether AI actually recommends you sits outside your analytics entirely, because it happens before any click exists to measure. Our guide to measuring AI share of voice covers how to run that side.

    How do you read AI crawler hits in server logs?

    Crawler hits are a leading indicator, and they are a completely different signal from human referral traffic. A crawler visit means a model can see the page. A referral visit means a human acted on it. The first has to happen before the second can.

    Vendors run separate bots for separate jobs, and the distinction matters when you read logs. OpenAI documents four: `GPTBot` for foundation-model training, `OAI-SearchBot` for surfacing sites in ChatGPT search, `ChatGPT-User` for fetches triggered by a user's question, and `OAI-AdsBot` for ad page safety checks (OpenAI developer documentation, accessed 20 July 2026). Anthropic runs `ClaudeBot` for training, `Claude-SearchBot` for search indexing and `Claude-User` for user-triggered fetches. Perplexity runs `PerplexityBot` for indexing and `Perplexity-User` for real-time retrieval.

    The user-triggered agents are the interesting ones. A spike in `ChatGPT-User`, `Claude-User` or `Perplexity-User` hits on a given URL means live buyers are asking questions that route the model to that page right now. Training-crawler volume tells you far less about current demand. Filter your log analysis by that split rather than lumping all AI bots together. The full token list is in our AI crawler user agents reference.

    One practical caveat: verify by reverse DNS or published IP ranges rather than trusting the user-agent string. Spoofing an AI crawler token is trivial, and inflated crawler counts have misled more than one team into thinking they were winning.

    Why referral analytics alone will mislead you

    Here is the number that reframes the whole exercise. Semrush's ghost citations study found that 62% of AI citations never name the brand being cited. The model uses your page as a source, produces an answer from it, and the reader gets the information without your name and often without a reason to click.

    Set that alongside how assistants behave. ChatGPT and Gemini often hide their citations entirely, while Perplexity and Claude expose theirs. And the same AI query changes its answer roughly 70% of the time (SparkToro), so a single check of any kind, referral or otherwise, is a snapshot of a moving target.

    What follows is not that GA4 is useless. It is that GA4 measures the click-through slice, and the click-through slice is a minority of AI-assisted discovery. A brand can be named in thousands of answers a month and see modest referral numbers, which looks like failure in analytics and is not. The reverse also happens: healthy referral traffic from one assistant while three others never mention you.

    The honest setup is both. Use the GA4 build above to measure what converts, and answer-share measurement to see whether you are in the conversation at all. Neither substitutes for the other, and the interesting insight is usually in the gap between them. If you want the background on why this split exists, start with what AI search is and the current AI search statistics.

    Where to start

    Build the custom channel group first, it takes ten minutes and immediately stops AI traffic hiding inside Referral. Add the exploration to see landing pages. Then treat your log data as the early-warning layer and answer-share as the reality check on the other 62%. If your landing-page data shows assistants sending people to pages you did not expect, our guide on how to get cited by AI explains what those pages tend to have in common.

    Before you spend a quarter optimising for referral numbers, find out whether assistants name you at all. Run a free check with Honeyb (our product) at /tools/ai-visibility-checker and see which engines recommend you, which name competitors instead, and what they cite.

    Frequently asked questions

    Why is my ChatGPT traffic showing as Direct instead of a referral in GA4?

    Almost always because the visit came from the ChatGPT mobile app, which opens links in an in-app browser without a referrer header. GA4 has nothing to read, so it defaults to Direct. Copy-pasted URLs from answers do the same thing. Neither is fixable from your side, which is why referral totals systematically understate AI-driven visits.

    Does GA4 track AI traffic automatically now?

    Partly. Google added an AI Assistant channel to the GA4 default channel group on 13 May 2026, matching a medium of ai-assistant or a referrer on Google's internal assistant list, described in the support documentation as sources like ChatGPT, Gemini, DeepSeek, Copilot and Grok. Perplexity and Claude are not named in that list, so a custom channel group is still worth building.

    What regex should I use for an AI traffic channel in GA4?

    Anchor a pattern to the hostnames in the table above, covering chatgpt.com, chat.openai.com, claude.ai, perplexity.ai, gemini.google.com, bard.google.com, copilot.microsoft.com, deepseek.com, grok.com and meta.ai. Order the rule above Referral in your channel group, because GA4 assigns on first match and Referral will otherwise claim the traffic first.

    Is AI referral traffic worth measuring if most discovery produces no click?

    Yes, but only as one of two measurements. Referral data tells you what AI-sourced visitors do once they arrive, which is the only way to judge whether that traffic converts. It cannot tell you whether assistants recommend you, since Semrush found 62% of AI citations never name the brand cited. Pair it with answer-share monitoring.

    How do I tell AI crawler hits apart from real AI referral visits in logs?

    Crawler hits carry a bot user agent such as GPTBot, ClaudeBot or PerplexityBot and no human session follows. Referral visits carry a normal browser user agent with an assistant hostname as referrer. Watch the user-triggered agents specifically, ChatGPT-User, Claude-User and Perplexity-User, since those fire when a live buyer's question routes a model to your page.

    Matiss Katanenko

    About the author

    Matiss Katanenko

    Co-founder, Honeyb

    My name is Matiss Katanenko and I co-founded Honeyb, the AI visibility platform that tracks how ChatGPT, Gemini, Claude, Perplexity and the other major AI engines talk about brands. I'm based in Riga, Latvia. Before Honeyb I spent years on the agency side running SEO and content programs for fast-growing brands across the US and Europe. That work is where I watched AI search start to compress the entire discovery channel into a four-brand short list, and decided to build the tool I wished agencies had. In my free time I'm in the sauna, on a padel court, or behind a drum kit.

    Connect on LinkedIn
    Honeyb

    Free to start

    See your brand through every major AI model.

    Run a free check in 30 seconds. The picture is usually different than you'd expect.

    ChatGPTChatGPT
    ClaudeClaude
    GeminiGemini
    PerplexityPerplexity