How to track users and sessions from ChatGPT and other language models in Google Analytics 4?
š How to track users and sessions from ChatGPT and other language models in Google Analytics 4?
As language models like ChatGPT, Copilot, Claude, and Perplexity become more widely used, a new source of website traffic is emerging. These AI tools often suggest links to websites, and users follow those links through their browsers. If you're running a website, it's important to understand how much traffic you're getting from these tools and how those users behave.
Google Analytics 4 (GA4) does not automatically categorize this traffic in a visible way. However, by configuring GA4 to detect traffic from known AI referrers, you can begin to track and analyze it effectively.
The goal is to set up tracking in GA4 that will help you:
šÆ 1. Identify how many users and sessions come from AI tools like ChatGPT. šÆ 2. Categorize that traffic under a custom group (for example, "AI Traffic"). šÆ 3. Analyze the behavior of these users compared to other traffic sources.
š How to track users and sessions from ChatGPT in GA4?
When a user clicks a link in an AI interface, such as ChatGPT, the browser typically includes a referrer header. This referrer tells GA4 which site the user was on before visiting your site.
For example:
š¤ ChatGPT typically sends the referrer chat.openai.com
š¤ Copilot sends copilot.microsoft.com
š¤ Claude may send claude.ai
š¤ Perplexity sends perplexity.ai
This referrer information is what you will use to identify AI-origin traffic in GA4.
š How to Track Traffic from ChatGPT in GA4 Step by Step?
Step 1: Initial Setup š§
- Open your GA4 property and go to Reports > Acquisition > Traffic acquisition.
- Add a secondary dimension called Session source or Session source/medium.
- Alternatively, switch the primary dimension to Session source.
- Look through the list of sources for domains like:
chat.openai.com
copilot.microsoft.com
claude.ai
perplexity.ai
you.com
If you find any of these, you're already receiving traffic from AI tools.
Step 2: Create a Custom Channel Group šÆ
Create a Custom Channel Group for AI Traffic To better track this traffic over time, create a custom channel grouping.
- Go to Admin > Data Settings > Channel Groups.
- Click Create new channel group.
- Add a new channel with a name like "AI Traffic".
- Add a rule for the new channel using the referrer values. Example:
Session source contains
chat.openai.com
OR session source containscopilot.microsoft.com
OR session source containsclaude.ai
OR session source containsperplexity.ai
OR session source containsyou.com
Save and publish the channel group. This will allow you to see AI traffic as a distinct group in your reports going forward. Note that custom channel groups only apply to data from the moment they are created onward.
Step 3: Build an Exploration Report š
Build an Exploration Report for AI Visitors To better understand how AI-sourced users behave:
- Go to Explore in GA4 and start a new blank exploration.
- Click Segments, then Create a custom user segment.
- Set conditions like:
Session source contains
chat.openai.com
ORcopilot.microsoft.com
, etc. - Apply the segment to your exploration and include metrics such as:
- š Sessions
- ā±ļø Engagement time
- šÆ Conversions
- š Bounce rate
This gives you a focused view of how users from language models interact with your site.
š” Why This Matters
Traffic from language models is a growing source of visibility. These users are often looking for answers, recommendations, or tools and can be highly qualified. By identifying and analyzing this traffic, you can: š Understand how much value AI tools bring to your site. šÆ Adjust your content strategy to better align with what AI tools are surfacing š Measure how this new segment compares to traditional traffic sources like search or social.
Tracking AI-based traffic in GA4 is both possible and valuable. Without relying on UTM parameters, you can use referrer data to:
š Identify users coming from ChatGPT, Copilot, Claude, and other models. š Organize them under a custom traffic category. š Analyze their behavior for better decision-making.
Taking time to set this up will give you deeper insight into one of the fastest-growing digital traffic channels.