Track LLM Traffic in Google Analytics 4 (GA4)


As AI search engines are becoming more used every day it became crucial to understand how much traffic they're driving to your website. Here's a step-by-step guide to tracking organic traffic from AI sources like ChatGPT, Claude, Perplexity, and Gemini in Google Analytics 4.
Setting Up LLM Traffic Tracking
- Log into your Google Analytics 4 account
- Navigate to Reports > Acquisition > Traffic acquisition
- Click the Add filter button (+ icon)

- Select Session source / medium as your dimension
- Choose "Matches regex" as the operator
- Paste the following regex pattern:
^*\.openai.*|.*copilot.*|.*chatgpt.*|.*gemini.*|.*gpt.*|.*neeva.*|.*writesonic.*|.*nimble.*|.*perplexity.*|.*google.*bard.*|.*bard.*google.*|.*bard.*|.*edgeservices.*|.*bnngpt.*|.*gemini.*google.*$

This regex pattern will capture traffic from popular AI sources including:
- ChatGPT and OpenAI
- Google Gemini
- Perplexity AI
- Microsoft Copilot
- Google Bard (legacy)
- Claude (via edgeservices)
- Other AI assistants

Understanding Your AI Traffic Data
Once you've applied the filter, you'll see a breakdown of sessions originating from AI sources. This data can help you:
- Measure the effectiveness of your GEO strategies
- Understand which AI platforms drive the most traffic
- Track changes in AI-driven traffic over time
- Compare AI traffic with traditional search engine traffic
Pro Tips
- Create a Custom Report: Save this view as a custom report for easy access
- Segment Analysis: Compare AI traffic behavior with traditional organic traffic
- Monitor Trends: Watch for emerging AI sources and update your regex as needed
Tracking AI traffic in Google Analytics 4 is a crucial step in understanding the impact of your GEO efforts. By implementing proper tracking, you can make informed decisions about your content strategy and ensure you're effectively reaching audiences through both traditional search and AI platforms.
Smart SEO,
Faster Growth!
Most Read Articles

Generative Engine Optimization (GEO)
Learn how Generative Engine Optimization (GEO) helps your content rank in AI search engines like ChatGPT and Google AI. This comprehensive guide explains the differences between SEO and GEO, why it matters for your business, and practical steps to implement GEO strategies for better visibility in AI-generated responses.

Track LLM Traffic in Google Analytics 4 (GA4)
Learn how to track and analyze traffic from AI sources like ChatGPT, Claude, Perplexity, and Google Gemini in Google Analytics 4. This step-by-step guide shows you how to set up custom filters to monitor AI-driven traffic and make data-driven decisions for your content strategy.

How to Humanize AI Text with Instructions
Learn practical techniques to make AI-generated content sound more natural and human. This guide covers active voice, direct addressing, concise writing, and other proven strategies to transform robotic text into engaging content.

Open AI Revenue and Statistics (2024)
Comprehensive analysis of OpenAI financial performance, user engagement, and market position in 2023. Discover key statistics including $20B valuation, $1B projected revenue, and 100M+ monthly active users.