Track ChatGPT traffic in GA4: where is your AI traffic hiding?
Spoiler: in Referral, Direct and Unassigned. Let's bring it home.
I am Abhinay Gupta, an eCommerce SEO consultant with 8+ years of experience. Pick your AI platforms and get the GA4 channel group regex, a Looker Studio formula, BigQuery SQL and a capture snippet that carries the AI source to the order. Then upload your GA4 export and see how much AI traffic you have, how it converts and where it is misfiled. Most guides give you a static regex. This builds the setup and audits your data.
Written by Abhinay Gupta, eCommerce SEO consultant. Last reviewed November 2026. Hire me for your store →
How do you track ChatGPT, Perplexity and Gemini traffic in GA4?
Create a custom channel group in GA4 under Admin, Data display, Channel groups. Add a channel called AI Traffic with the condition Source matches regex, and paste a pattern that lists the AI platforms' domains, such as chatgpt.com, perplexity.ai and gemini.google.com. Move it above Referral so GA4 applies it first, then select the group in your reports. This builder generates the pattern for the platforms you pick. Expect an undercount, because copy-pasted links and stripped referrers appear as Direct.
Build your AI traffic setup
Tick the platforms you want to count. The outputs below update as you go.
- Admin, Data display, Channel groups, Create new channel group.
- Add channel named AI Traffic. Condition: Source, matches regex. Paste the pattern.
- Drag AI Traffic above Referral. Save.
- In reports, choose the new group as the channel dimension.
Create a calculated field. Rename the source field if yours differs.
Replace the project and dataset. Test on one day and compare with GA4.
Test on staging first. It stores the first AI referral for 30 days and pushes an ai_referral event.
Audit your GA4 export
Export a table with Session source (or source / medium), sessions, key events and revenue as CSV. The file is read in your browser.
Drop your GA4 CSV here
| Platform | Sessions | Key events | Rate | Revenue |
|---|
Scan for new AI tools I may not list yet.
| Source | Sessions |
|---|
What GA4 can and cannot see
| Situation | Where it shows up | What to do |
|---|---|---|
| Click from chatgpt.com, perplexity.ai and similar | Referral, or your AI channel after setup | Use the regex group |
| Link with utm_source but no medium | Sometimes Unassigned | Check Unassigned for AI sources |
| Copy-pasted link or app that strips the referrer | Direct | Add a "How did you hear about us?" option that lists AI tools |
| Person sees your brand in an AI answer, then searches | Organic or Direct | Watch branded search and survey answers |
| Google AI Mode and AI Overviews clicks | Organic Google | Cannot be separated in GA4 |
| Agent-completed purchases | May create no pageviews | Log order source server-side |
Method: platform domains were reviewed in November 2026 from public guides and tested patterns. Platforms change domains without notice, so review the regex quarterly. The export analyzer classifies by the same regex.
How this differs from typical GA4 AI traffic guides
| Question | Typical guide | This builder |
|---|---|---|
| Regex | One fixed pattern to copy | Built from the platforms you choose, with your own domains |
| Where it works | GA4 only | GA4, Looker Studio, BigQuery and a capture snippet |
| Your data | Not checked | Upload your export to see AI sessions, rate, revenue and misfiled rows |
| Honesty | Varies | States what GA4 cannot see |
This describes the general pattern of guides I reviewed in November 2026, not every guide.
Track ChatGPT traffic in GA4: what this builder sets up
This builder creates the GA4 setup to track ChatGPT traffic and other AI traffic in GA4: a channel group, a report filter and an exploration so you can see AI referrals next to organic search.
This is the quickest way to track AI traffic in GA4: set it up once, then compare ChatGPT traffic in GA4 against organic search.
Sources and further reading
1 sources
Public sources behind the claims on this page. Links open the original. Checked November 2026.
- Google: AI features and your websiteEligibility and controls for AI Overviews and AI Mode.

Abhinay Gupta, freelance eCommerce SEO consultant
I have worked in SEO for 8+ years, across eCommerce, technical SEO and AI search. I have led SEO teams at Appinventiv and Restroworks and now work hands-on with stores on Shopify, WooCommerce, BigCommerce, Magento and custom builds. I write only about work I have done, and I say so when something is unproven.
LinkedIn · Upwork · About · Editorial policy · Case studies · Book a call
Reviewed November 2026. How I research and review. Figures come from the sources named on the page, or from my own Search Console and Google Analytics data where stated.
GA4 AI traffic tracking FAQ
Why does AI traffic not show up as its own channel in GA4?
GA4's default channel groups were not built for AI assistants, so visits from chatgpt.com or perplexity.ai usually fall under Referral, and some land in Direct or Unassigned. A custom channel group with a source regex pulls them into one AI channel.
Where do I put the regex in GA4?
In Admin, under Data display, open Channel groups and create a new group. Add a channel named AI Traffic, set the condition to Source matches regex and paste the pattern. Then drag AI Traffic above Referral, because GA4 applies the rules from top to bottom. The exact menu names can change, so check them against the current GA4 interface.
Does a custom channel group change my past data?
In GA4, custom channel groups apply to historical data in reports, because they are applied when you view the data. They do not change the default channel group, so keep both.
Will this catch all AI traffic?
No. Only visits that pass a referrer or a UTM tag are visible. Copy-pasted links, apps that strip the referrer, and people who see your brand in an AI answer and then search for you later all show up as Direct or Organic. Treat the number as a floor.
Can I separate Google AI Mode and AI Overviews from normal organic traffic?
Not reliably in GA4. Those clicks arrive from Google, so they look like organic Google traffic. Search Console reporting and your own testing are the available signals.
Why is some ChatGPT traffic in Unassigned?
Reports describe ChatGPT links sometimes carrying a utm_source value without a medium, which can leave sessions unassigned. The builder's rule order and the export analyzer help you spot this. Check your own data, because platform behaviour changes.
Which AI platforms does the builder include?
ChatGPT, Perplexity, Gemini, Copilot, Claude, Meta AI, DeepSeek, Grok, Mistral, You.com, Phind and Poe. The list was reviewed in November 2026. Review your regex every quarter, because platforms change domains without notice.
Is the GA4 export I upload sent anywhere?
No. The analyzer reads the CSV in your browser. Nothing is uploaded.
What export should I upload?
In GA4, build a Free-form exploration or a Traffic acquisition report with Session source or Session source / medium, plus sessions, key events and revenue, then export as CSV. The analyzer finds the columns by name.
What is the capture snippet for?
It stores the first AI referral on a visitor's device and sends it to your data layer, so you can attach it to the order. That helps when the last click is no longer the AI visit. Test it on staging first.
How accurate is the BigQuery query?
It is a starting point. GA4 export fields differ by property and date, and referrer data can sit in different places. Run it on a small date range and compare it with the GA4 report before trusting it.
Can you set up AI attribution for my store?
Yes. I set up GA4, GTM and reporting for eCommerce stores. Use the contact button.
Get your GA4 AI traffic tracking set up
I work with online stores as a freelance eCommerce SEO consultant. Book a 30-minute call, or send a short brief with your site and goal. You get a specific answer, not a sales script. See my eCommerce SEO services or why hire a freelance consultant.