July 26, 20267 min readBetterGA Team

How to Track AI Referral Traffic in GA4 (ChatGPT, Claude, Perplexity & Gemini)

Learn how to track and isolate traffic from AI search engines like ChatGPT, Claude, Perplexity, and Gemini in GA4 using custom channel groups, regex, and reports.

GA4AI TrafficChannel GroupsAcquisitionReporting

If you look closely at your analytics, you might notice something surprising: traditional search engine traffic is shifting, and visits coming from AI platforms like ChatGPT, Perplexity, Claude, and Google Gemini are quietly growing.

Generative Engine Optimization (GEO) and AI search engines are now standard discovery tools for millions of users. However, if you rely solely on default GA4 setups, much of this valuable traffic gets buried, misclassified, or lumped into generic Referral or Direct buckets.

Tracking AI-driven referral traffic accurately gives you clear answers to critical questions:

  • Are users finding your products or articles through AI recommendations?
  • Which AI tools generate the highest conversion rates and longest sessions?
  • How much organic traffic has migrated from traditional SERPs to AI search tools?

This practical guide shows you how GA4 handles AI traffic, how to set up native and custom AI channels step by step, and how to capture traffic from modern AI platforms.


The Problem: Why GA4 Often Misses or Misclassifies AI Traffic

When a visitor clicks a link provided by an AI chatbot or search engine, their web browser sends HTTP header referrer information to your website.

For standard web referrers (e.g., chatgpt.com or perplexity.ai), GA4 records the source correctly. However, standard GA4 default channel groupings were historically built around traditional web channels (Organic Search, Referral, Paid Search, Social).

Without proper categorization, GA4 creates three main tracking challenges:

  1. Lumped into General Referral: Visits from chatgpt.com or claude.ai get mixed in with thousands of unrelated website referrers, making overall AI performance hard to measure.
  2. Logged as Direct or (not set): Mobile apps or desktop clients (such as the ChatGPT desktop application) often strip HTTP referrer headers entirely. When no referrer exists, GA4 classifies the visit as Direct.
  3. Inconsistent Naming: Referrers appear under multiple variations (e.g., chat.openai.com, chatgpt.com, ios-app://com.openai.chatgpt, gemini.google.com), scattering your reporting across dozens of line items.

Method 1: Using GA4's Native "AI Assistant" Channel Group

GA4 includes a default channel classification known as AI Assistant.

How it works

When GA4 recognizes incoming traffic from a known AI origin, it automatically assigns:

  • Default Channel Group: AI Assistant
  • Medium: ai-assistant
  • Campaign: (ai-assistant)

How to view it in GA4

  1. Open GA4 and navigate to Reports > Acquisition > Traffic acquisition.
  2. Change the primary dimension dropdown from Session default channel group to view the channels.
  3. Look for the AI Assistant row in your channel breakdown.
+------------------------------+----------+--------------+
| Session default channel group| Sessions | Key Events   |
+------------------------------+----------+--------------+
| Organic Search               |   12,450 |          320 |
| AI Assistant                 |    1,840 |           65 |
| Direct                       |    4,200 |           90 |
+------------------------------+----------+--------------+

[!NOTE] Limitations of Native Tracking: The native AI Assistant channel only categorizes traffic moving forward from its release date and may omit smaller, region-specific, or rapidly emerging AI tools (like DeepSeek, Poe, Phind, or custom API wrappers).

To ensure complete coverage, setting up a Custom AI Channel Group is recommended.


Creating a dedicated AI Traffic custom channel group allows you to aggregate every AI platform under one roof without altering your underlying raw data.

Step-by-Step Configuration

Step 1: Open Channel Groups in Admin

  1. Go to Admin (bottom-left gear icon).
  2. Under Data display, click Channel groups.
  3. Locate Default Channel Group, click the three dots on the right, and select Copy to create new.

Step 2: Name Your New Channel Group

Set the Channel group name to Default Channel Group + AI.

Step 3: Add the New "AI Traffic" Channel

  1. Click Add new channel.
  2. Set the Channel name to AI Traffic.

Step 4: Configure the Regex Matching Rules

Under Define channel rules, set the condition:

  • Dimension: Session source (or Source)
  • Match type: matches regex
  • Value: Paste the optimized AI referrer regex pattern below:
.*chatgpt.com.*|.*openai.com.*|.*perplexity.*|.*claude.ai.*|.*gemini.google.com.*|.*copilot.microsoft.com.*|.*grok.x.ai.*|.*meta.ai.*|.*you.com.*|.*phind.com.*|.*poe.com.*|.*deepseek.com.*
+-------------------------------------------------------------------+
| Rule Configuration                                                |
| Dimension: Session source                                         |
| Condition: matches regex                                          |
| Pattern:   .*chatgpt.com.*|.*perplexity.*|.*claude.ai.*|...       |
+-------------------------------------------------------------------+

Step 5: Prioritize Channel Order

Drag your new AI Traffic channel up to position #1 or #2 (above standard Referral). Channel groups evaluate conditions from top to bottom; putting AI Traffic first ensures GA4 doesn't categorize a visit as generic Referral before checking your AI rules.

Step 6: Save

Click Save Channel.


Method 3: Historical Analysis Using GA4 Explorations

Because custom channel groups only apply to reporting from the day they are created, you can use GA4 Explorations to analyze past AI traffic immediately.

How to Build an AI Referral Exploration Report:

  1. In GA4, go to Explore and click Blank.
  2. Name your exploration AI Traffic Analysis.
  3. Under Dimensions, import:
    • Session source / medium
    • Page referrer
    • Landing page + query string
  4. Under Metrics, import:
    • Sessions
    • Engaged sessions
    • Engagement rate
    • Key events (Conversions)
    • Total revenue
  5. Drag Session source / medium into the Rows area.
  6. Drag your metrics into the Values area.
  7. Scroll down to Filters and add:
    • Dimension: Session source
    • Condition: matches regex
    • Expression: .*chatgpt.*|.*perplexity.*|.*claude.*|.*gemini.*|.*copilot.*|.*deepseek.*

This reveals historical volume, user behavior, and revenue generated from AI referrals.


Common AI Referrers Cheat Sheet

Here is a quick reference table of common AI search engines and their recorded GA4 referral signatures:

AI PlatformCommon GA4 Session source ValuesNotes
ChatGPTchatgpt.com, chat.openai.com, ios-app://com.openai.chatgptMobile app clicks often show up with app URI prefixes or as Direct.
Perplexity AIperplexity.ai, www.perplexity.aiHigh intent traffic; often includes citations linking directly to sources.
Claude (Anthropic)claude.aiReferral links are passed when artifact output or chat links are clicked.
Google Geminigemini.google.comGemini web interface citations pass explicit domain referrers.
Microsoft Copilotcopilot.microsoft.com, bing.comSometimes passes bing.com as referral source.
DeepSeekdeepseek.com, chat.deepseek.comGrowing traffic source for technical and developer documentation.

Understanding "Dark AI Traffic" & Tracking Limits

While tracking HTTP referrers works well for browser-based AI chats, it is important to understand what GA4 cannot see:

  • Desktop & Native Mobile Apps: If a user opens a native desktop application and clicks a link without an embedded web browser context, the HTTP referrer header may be dropped, resulting in Direct traffic.
  • Zero-Click AI Answers: When AI tools synthesize an answer using your content without the user clicking the source link, GA4 will record zero traffic. This is known as "Zero-Click Search."
  • Prompt Content: Search engines do not pass the prompt text entered into the AI tool due to privacy controls.

Pro Tip for Capturing Dark AI Referrals

Add a lightweight, optional single-question survey on high-intent conversion pages or signup forms:

"How did you first discover us?" [ Search Engine ] [ ChatGPT / AI Tool ] [ Social Media ] [ Recommendation ]

Comparing self-reported attribution against GA4 AI referral data often reveals that actual AI-assisted discovery is 2x to 3x higher than referrer logs alone suggest.


Monitoring AI Traffic Without GA4 Interface Clutter

Setting up channel groups in GA4 helps categorize data, but checking multiple reports every week inside GA4 can feel repetitive and complex.

If you prefer clean, instant access to your key GA4 metrics without navigating through complex exploration tables or waiting for Looker Studio reports to load, Better GA provides a simplified dashboard connected directly to your GA4 property, complete with automated weekly and monthly summaries delivered to your inbox.

Keep the setup simple

Use BetterGA to check your numbers without fighting GA4.

Once your tracking is live, BetterGA gives you a cleaner view of your traffic, top pages, and growth trends without the usual Google Analytics clutter.