11/02/2024

How To Track AI Traffic in GA4

Learn how to track and analyze AI chatbot traffic in GA4 with custom channel groups. Follow our step-by-step guide to monitor ChatGPT, Gemini, and other AI sources.

Updated Nov 3 2024 – New regex and report details

AI is now officially sending converting traffic to websites at a decent pace and it’s only going to increase. I wanted to see how much AI traffic a site is getting in GA4 and if we can glean any interesting insights from it. There may be a better way to do this, but until then I’m pretty happy with what I’ve come up with.

It took a lot of troubleshooting, but I’m ready to release this method in to the wild for you all to play with yourselves. Here’s all you need to know to do this in your own GA4 property.

Step 1: Set Up Your AI Channel Group

First things first, you need to tell GA4 what counts as “AI traffic.” Here’s how you do it:

  1. Head over to Admin > Data Display > Channel groups
  2. Create a new Custom Channel Group
  3. Name your group name something like “AI Channel Group”
  4. Click Add new channel
  5. Name your channel “AI”
  6. Here’s the magic sauce – set up these channel conditions:
    • Source – partially matches regex – see regex code below
    • Add an OR condition
    • Source – ends with – .ai
  7. Click Save channel
  8. Click Reorder and move your AI channel to position 1
  9. Click Save Group

Regex

(openai|chatgpt|anthropic|claude|perplexity|gemini|copilot|grok|cohere|poe|huggingface|phind|llama|meta|consensus|elicit|ghostwriter|you\.com)

Your channel details should look like this:

How To Track AI Traffic in GA4 1

Quick note: This data is retroactive so whenever you update your conditions your report will update accordingly.

Step 2: Build Your Exploration Report

Alright, now for the fun part. We’re going to create a report that actually tells you something useful about your AI traffic. This report will show sources, landing page, sessions, events, and key events. Once you get this set up you can customize it to show whatever you want.

The Setup

  1. Go to the “Explore” section in GA4
  2. Name your tab Sources

Variables

  1. Set the date range to last 28 days (you can change this later)
  2. Add your dimensions:
    • Session source
    • Event name
    • Session AI Channel Group (or whatever you named it in Step 1)
    • Landing page + query string
    • Is key event
  3. Add your metric:
    • Sessions
    • Engaged sessions

Settings

  1. Technique = Free form
  2. Visualization = Table
  3. Rows = Session source
  4. Values = Engaged sessions, Sessions
  5. Filter = Session AI Channel Group – exactly matches – AI – this is case-sensitive!

This is what it looks like for one of our clients:

How To Track AI Traffic in GA4 2

That’s pretty cool, but now you can create new tabs that show landing pages and key events.

Landing Pages Report

  1. Duplicate the Sources tab
  2. Rename this tab Landing Pages
  3. In Rows – Replace Session source with Landing page + query string

Key Events Report

  1. Duplicate the Sources tab again
  2. Rename this tab Key Events
  3. Rows = Sessions source
  4. Columns = Event name
  5. Values = Engaged sessions, Sessions
  6. Filters – Keep the previous filter and add a 2nd filter
    • Is key event – exactly matches – true

Now we see that a user from chatgpt submitted a form to get a download!

How To Track AI Traffic in GA4 3

What Do You Do Now?

Now you can see how users visiting your site from AI sources are interacting with it. I’d recommend playing around with these explorations and create reports that give insight in to your goals. Maybe you’ll find that AI users are leaving without doing anything else. In that case you could review your landing pages to see if users are getting a negative experience.

Pro tip: Watch your landing pages carefully. AI tools often send users to very specific content, and you might find some surprising patterns.

A Heads Up About the Future

I expect Google to eventually add a dedicated AI channel instead of dumping everything in the referral bucket. Until then, this custom setup is your best bet for tracking this stuff.

Quick Troubleshooting

If you’re not seeing AI traffic when you know it’s there:

  • Double-check that regex pattern and your settings
  • Make sure your GA4 setup isn’t blocking these referrers
  • Give it 24-48 hours for data to show up, but I suspect you will see something right away

Remember, AI traffic patterns are still evolving. What works today might need tweaking tomorrow, but at least you’ll have the foundation to track it all.

Keep an eye on this stuff – the way people find websites is changing fast, and you’ll want to know where your traffic is really coming from. I’ve already updated this article since it was first posted to include more AI sources.

Let us know if this helped you or if you have any questions or comments. See a more elegant way to do this? Hit us up!

Our most popular articles

How To Track AI Traffic in GA4

8-Letter Bingos and High Scoring Triple-Triples: How to Turbo Charge Your Scrabble Game

Do You Really Need to Verify a Domain Property in Search Console?

Author
Have any thoughts to share? We love challenging conversations.
Reach out to discuss this article.

Related articles

Learn how to track and analyze AI chatbot traffic in GA4 with custom channel groups. Follow our step-by-step guide to monitor ChatGPT, Gemini, and other…
There are over 30,000 8-letter bingos that can be played in a Scrabble game. But don’t despair, we’ve done the work to curate the top…
In a few minutes of clicking around, identify opportunities to increase your visibility and click through….

SIGN UP FOR RANDOM, INFREQUENT EMAILS

Reach out to discuss this article.

This field is for validation purposes and should be left unchanged.