Skip to main content
When a shopper asks ChatGPT “what running shoes should I buy?” and clicks through to your store, that session arrives with no referrer and no UTM parameters. GA4 logs it as Direct. It is not direct — it is AI-driven commerce, and it converts at 15.9% compared to 1.76% from Google Organic. The gap between what GA4 shows you and what is actually driving your revenue is called dark agentic traffic, and it grows every month as AI assistants become the default starting point for product discovery.

Why AI traffic loses its referrer

Several distinct mechanisms cause AI-sourced visits to arrive without attribution signals. Understanding them helps you appreciate why no simple UTM rule fixes the problem.
CauseWhat happens
Server-side requestsAI agents fetch pages server-side; no browser referrer header is ever set
Referrer strippingChatGPT, Perplexity, and others deliberately strip or omit Referer headers
Click proxyClicks through AI chat interfaces pass through a proxy that removes the referrer
No UTM parametersAI surfaces do not append UTM params to outbound links
HTTPS → HTTP redirectReferrer is dropped whenever a redirect crosses protocol boundaries

What dark traffic looks like before and after Asva

Without attribution, a meaningful share of your Direct channel is actually AI Commerce. Here is a representative before-and-after for a mid-size DTC brand:
Direct          34%   ← includes ~17% misattributed AI traffic
Organic Search  28%
Paid Search     22%
Email            9%
Social           7%
The Direct channel drops by half. A brand-new top-five channel appears — one that was already converting at multiples of paid search.

How Asva identifies AI-sourced sessions

Asva’s attribution engine combines multiple signals to classify a session. No single signal is reliable on its own, so Asva weights them together and assigns a confidence score.

Session fingerprinting

Timing and behavioral patterns differ measurably between AI-referred visits and organic direct visits.

Landing page signals

AI surfaces almost always deep-link to a specific product or category page, not the homepage.

UTM fallback

When an AI surface does pass partial UTM data (e.g. utm_medium=ai), Asva captures and normalizes it.

Known referrer domains

Recognized AI referrer domains — chatgpt.com, gemini.google.com, perplexity.ai — are classified at high confidence when the header is present.
Attribution is probabilistic for sessions with no referrer signal. Asva applies a confidence score to each classified session. Sessions below the confidence threshold are reported separately so you can review them. See How Asva’s Attribution Model Works for full details.

What you can measure after installation

Once the snippet is live, Asva surfaces the following in your dashboard and in GA4:
  • AI Commerce channel — a new named channel alongside Organic, Paid, and Direct
  • Per-surface attribution — traffic broken down by ChatGPT, Gemini, Perplexity, and others where the referrer is detectable
  • Product-level AI traffic — which products AI assistants recommend most
  • AI-sourced revenue — conversion rate and revenue attributed to AI sessions
  • Month-over-month trend — whether your AI traffic share is growing

Install the attribution snippet

Add the Asva snippet to your storefront <head> before any other analytics tags.
1

Copy the snippet

<!-- Asva AI Dark Traffic Attribution -->
<script>
  (function(w,d,s,l,i){w[l]=w[l]||[];
  w[l].push({'asva.start': new Date().getTime(), event:'asva.js'});
  var f=d.getElementsByTagName(s)[0],
  j=d.createElement(s),dl=l!='asvaLayer'?'&l='+l:'';
  j.async=true;j.src='https://cdn.asva-ai.com/attribution.js?id='+i+dl;
  f.parentNode.insertBefore(j,f);
  })(window,document,'script','asvaLayer','YOUR_PROPERTY_ID');
</script>
2

Replace YOUR_PROPERTY_ID

Find your Property ID in your Asva dashboard under Settings → Property. Replace YOUR_PROPERTY_ID in the snippet with that value.
3

Place it in your storefront

Paste the snippet inside the <head> tag on every page of your storefront. For platform-specific placement, see the tabs below.
Go to Online Store → Themes → Edit code → theme.liquid and paste the snippet inside the <head> block.
4

Verify the snippet fires

Open your browser console on any page of your store and run:
console.log(window.asvaLayer)
You should see the asvaLayer array initialised. If you arrived from a link shared through a ChatGPT conversation, you will also see ai_source and is_ai_session populated.
Place the snippet in <head>, not before </body>. Asva must capture the referrer context on page load, before any navigation events fire. Loading it at the bottom of the page can cause the first-touch referrer to be missed.

Privacy and compliance

Asva’s attribution does not rely on third-party cookies. All session classification is:
  • Performed server-side on first-party data
  • Free of personally identifiable information (PII)
  • Compliant with GDPR, CCPA, and equivalent regulations

Next steps

GA4 Integration

Create custom dimensions and channel grouping rules so AI Commerce appears as a named channel in GA4.

How Asva's Attribution Model Works

Understand the signal tiers, confidence thresholds, and attribution windows Asva uses to classify sessions.