BEACON Guide

How to track ChatGPT & AI traffic in GA4.

AI assistants now send real visitors to your site — and they convert unusually well — but Google Analytics 4 lumps most of them into “Referral” or “Direct,” so you can’t see them. Here’s a copy-paste regex that matches the major AI engines, and the exact steps to build an AI-traffic view in GA4.

Start free Run a free check
The AI referrersChatGPT, Perplexity, Gemini, Claude and Copilot send traffic from their own domains — you just have to group them.
One regex does itA single regex on Session source captures every major AI engine in Explorations, segments or a channel group.
Exploration in 2 minutesThe fastest way to see it today: a Free-form Exploration filtered by the regex.
Or a permanent channelCreate a custom channel group so “AI” shows up automatically in every report going forward.
Mind the blind spotsSome AI apps strip the referrer, so a share of AI visits still lands in “Direct” — treat this as a floor, not the full number.
Why it mattersAI-referred visitors are high-intent and convert well — proving that ROI justifies your GEO work.

The short answer

In GA4, AI traffic arrives as referrals from the assistants’ own domains (chatgpt.com, perplexity.ai, gemini.google.com, claude.ai, copilot.microsoft.com). Group them with one regex on “Session source” — either as a filter in a Free-form Exploration (fastest) or as a rule in a custom channel group (permanent). Copy the regex below.

The copy-paste regex

Use this on the “Session source” dimension (RE2 / “matches regex”). It covers the major AI assistants and their alternate domains:

chatgpt\.com|chat\.openai\.com|openai\.com|perplexity\.ai|gemini\.google\.com|bard\.google\.com|claude\.ai|copilot\.microsoft\.com|edgeservices\.bing\.com|bing\.com/chat

Method 1 — a Free-form Exploration (fastest)

See it in two minutes without changing your setup:

  • Explore → Free form.
  • Add “Session source” as a row (or “Session source / medium”).
  • Add a Filter: Session source → matches regex → paste the regex above.
  • Add metrics: Sessions, Engaged sessions, Conversions.
  • You now have an AI-traffic breakdown by engine.

Method 2 — a permanent custom channel group

To make “AI” appear automatically in your standard reports: Admin → Data display → Channel groups → Create new channel group. Add a channel named “AI Assistants” with the condition “Session source matches regex” and paste the regex. Order it above “Referral” and “Organic Search” so AI visits are claimed by the AI channel first. New data is grouped going forward (it isn’t retroactive).

Caveats — why this is a floor, not the full count

Two honest limitations. First, some AI apps and native/mobile clients don’t pass a referrer, so those visits land in “Direct” and this regex can’t catch them — your true AI traffic is higher than what you’ll see. Second, engine domains change and new assistants launch, so revisit the regex periodically. Treat the number as a directional floor that’s still far better than not measuring at all.

From traffic to visibility

GA4 shows AI traffic that already arrived. To grow it, you also need to know whether AI engines mention and cite you in the first place — the prompts you win, the ones you lose, and to whom. That’s AI-visibility tracking (GEO), which GA4 doesn’t do; Beacon does, and pairs it with the SEO audit behind it.

FAQ

How do I track ChatGPT traffic in GA4?

Group visits from AI assistant domains using a regex on “Session source.” Add it as a filter in a Free-form Exploration for a quick view, or as a custom channel group to see “AI” in every report. Copy the regex in this guide.

What is the GA4 regex for AI traffic?

Match “Session source” against: chatgpt.com, chat.openai.com, openai.com, perplexity.ai, gemini.google.com, bard.google.com, claude.ai, copilot.microsoft.com (and bing chat). The full copy-paste regex is above.

Why does my AI traffic show as Direct in GA4?

Some AI apps and mobile/native clients don’t send a referrer, so those visits are attributed to “Direct” and can’t be matched by source. That’s why regex-based AI traffic is a floor — your real AI traffic is higher.

Does GA4 show whether AI engines recommend me?

No — GA4 only measures traffic that already arrived. Whether ChatGPT, Gemini or Perplexity actually mention and cite your brand for buyer prompts is AI-visibility (GEO) tracking, which is a separate tool like Beacon.

Measure your AI visibility, not just AI traffic

See which prompts ChatGPT, Gemini & Perplexity cite you for — free.

Start free Run a free check