Sign in
← Attribution docs
Documentation

How MTK Attribution categorizes

No guesswork, no black box — these are the exact values the engine looks for when it assigns every visit a channel and source. If a lead is ever categorized in a way you don't expect, this page tells you precisely why.

How channel & source are classified

channel and source are computed, not read from a single parameter. Classification runs once per session, on that session's first page load, from that page's URL parameters and referrer. The engine walks the rules below in order and the first match wins — these are the exact values it looks for. All comparisons are case-insensitive.

Rule 1
Paid AI

utm_medium is exactly paid_ai (changeable per license via the paidAiMedium config) — or utm_source names an AI platform (alias table below) alongside any paid medium: cpc, ppc, paid, paid_search, or paid_social. ChatGPT Ads' own macro example is utm_source=chatgpt&utm_medium=cpc, so the AI source decides — that click is never Paid Search. Exception: a Google / Microsoft click ID (gclid, gbraid, wbraid, msclkid) still wins, whatever the UTMs say.

Source: The canonical AI platform name (ChatGPT, Perplexity, …) in normalized mode; else utm_source title-cased; else ChatGPT when paid_ai arrives with no source at all.

Rule 2
Paid Search

A gclid, gbraid, wbraid, or msclkid URL parameter is present — or utm_medium is exactly cpc or paid_search.

Source: Microsoft Ads if msclkid (or a bing/bingads/microsoft utm_source); Google Ads when untagged or for google/googleads/adwords; any other utm_sourceper the source-format setting below. Paid-search sources always carry “Ads” in normalized mode so they can't be confused with organic.

Rule 3
Paid Social

utm_medium is exactly paid_social (changeable per license via the paidSocialMedium config).

Source: utm_source (per the source-format setting below); else Facebook.

Rule 4
Paid Social · TikTok

A ttclid URL parameter is present (and no rule above matched).

Source: Always TikTok.

Rule 5
Email

utm_medium is exactly email.

Source: utm_source (per the source-format setting below); else Email.

Rule 6
Organic AI (tagged)

utm_source names an AI platform (alias table below) with none of the paid signals above — ChatGPT appends utm_source=chatgpt.comto its outbound links, often with no referrer at all. Checked before the Campaign rule so an assistant's citation never reads as a campaign nobody ran.

Source: The canonical AI platform name in normalized mode (chatgpt.com → ChatGPT); verbatim mode passes the typed value through.

Rule 7
Campaign / Referral (tagged)

Any utm_source with none of the paid signals above. Channel is Referral when utm_medium is exactly referral, otherwise Campaign.

Source: utm_source (per the source-format setting below).

Rule 8
Organic AI (referrer)

No UTMs; the referrer hostname matches an AI-assistant domain (list below). Checked before the search-engine list on purpose: gemini.google.com and copilot.microsoft.com sit under search-engine hosts, and would otherwise classify as Organic Search.

Source: From the referrer — see the source-name table below.

Rule 9
Organic Search

No UTMs; the referrer hostname matches a search-engine domain (list below). Exception: a Google referrer with a fresh _gcl_aw cookie upgrades to Paid Search / Google Ads — an ad click whose gclid was lost in transit and recovered out of the cookie (see the cookie-rescue row below).

Source: From the referrer — see the source-name table below.

Rule 10
Organic Social

No UTMs; the referrer hostname matches a social domain (list below) — or an fbclid URL parameter is present alongside any referrer. Exception: a Facebook/Instagram referrer with a fresh _fbc cookie and no fbclid in the URL upgrades to Paid Social / Facebook — the cookie is only evidence of a paid click when the URL parameter went missing. Meta puts fbclid on every outbound link, organic posts included, and the Pixel writes _fbc from whichever one it sees, so a _fbc sitting next to an fbclid is just that click echoed back. Untagged Meta ads are indistinguishable from organic Facebook here — utm_medium=paid_social on ad URLs is what separates them.

Source: From the referrer — see the source-name table below.

Rule 11
Referral

No UTMs; any other referrer. A referrer from the site's own hostname never counts — internal navigation (idle-timeout session renewals, consent-delayed tag loads) is ignored for classification entirely.

Source: The referrer's hostname with www. stripped, e.g. partnersite.com.

Rule 12
Organic Social · Facebook

An fbclid URL parameter with no referrer at all (some in-app browsers strip it).

Source: Always Facebook.

Rule 13
Paid Search / Paid Social · cookie rescue

No click IDs, no UTMs, no (external) referrer — but a fresh platform cookie exists: _gcl_aw (Google) or _fbc (Meta) created within the session window. The ad click just happened; its URL signal was lost (consent redirect, URL rewrite, tag firing mid-session). The click ID is recovered out of the cookie into the touch. A stale cookie never classifies — those cookies live ~90 days, and a returning visitor is Direct.

Source: Google Ads (from _gcl_aw) or Facebook (from _fbc).

Rule 14
Direct

Nothing identifying — no click IDs, no UTMs, no referrer, no fresh platform cookies.

Source: Always Direct.

Built-in AI-assistant domains

A referrer from any of these classifies as Organic AI. Checked before the search-engine list. Extendable per license via the aiDomains config — an entry typed verbatim as utm_source counts as an AI source too.

chatgpt.comopenai.comperplexity.aiclaude.aigemini.google.combard.google.comcopilot.microsoft.comgrok.commeta.aideepseek.comyou.commistral.ai

Built-in search-engine domains

A referrer from any of these classifies as Organic Search. Extendable per license via the searchDomains config.

google.bing.yahoo.duckduckgo.ecosia.

Built-in social domains

A referrer from any of these classifies as Organic Social. Extendable per license via the socialDomains config.

facebook.fb.instagram.linkedin.twitter.x.comyoutube.reddit.pinterest.tiktok.t.co

Source names from referrers

When a rule derives source from the referrer, these hostname matches produce these names. Any referrer not listed reports its own hostname (minus www.) as the source — e.g. a visit from Ecosia is Organic Search / ecosia.org.

ChatGPT
chatgpt.comopenai.com
Perplexity
perplexity.ai
Claude
claude.ai
Gemini
gemini.google.combard.google.com
Copilot
copilot.microsoft.com
Grok
grok.com
Meta AI
meta.ai
DeepSeek
deepseek.com
You.com
you.com
Mistral
mistral.ai
Google
google.
Bing
bing.
Yahoo
yahoo.
DuckDuckGo
duckduckgo.
Facebook
facebook.fb.
Instagram
instagram.
LinkedIn
linkedin.
Twitter/X
twitter.x.comt.co
YouTube
youtube.
Reddit
reddit.
Pinterest
pinterest.
TikTok
tiktok.

How domains are matched

Matching runs against the referrer's hostname only — never its path or query string. Entries ending in a dot (google.) match that label anywhere in the host (google.com, news.google.de). Entries with an inner dot (x.com) match that exact domain or a subdomain of it — so x.com and www.x.com qualify, while wix.comdoes not. Custom entries with no dot at all match anywhere in the host. A referrer from the site's own hostname is ignored for classification entirely.

How utm_source becomes the source value

In normalized mode (the default), typed utm_source values are cleaned to canonical platform names — so paid, organic, and click-ID traffic from one platform share one spelling, and Meta's {{site_source_name}} values arrive readable. Values not in the table are title-cased. In verbatim mode (per-license toggle) typed values pass through byte-for-byte — engine-derived fallbacks (untagged clicks, referrers, cookie rescues) stay curated in both modes.

Facebook
fb
Instagram
ig
Messenger
msg
Audience Network
an
YouTube
youtube
LinkedIn
linkedin
TikTok
tiktok
DuckDuckGo
duckduckgo
Twitter/X
twitterx
Google Ads (paid)
googlegoogleadsadwords
Microsoft Ads (paid)
bingbingadsmicrosoft

The (paid)rows apply within Paid Search classification — where sources always carry “Ads” so a source pivot can't mix paid and organic Google or Bing traffic.

AI platform utm_source values

These utm_source values mark a visit as AI traffic — Organic AI on its own, Paid AI with a paid medium — and normalize to the same name the referrer produces, so tagged and untagged arrivals from one assistant share one spelling. Unlike paid search, the paid and organic source share the name (ChatGPT both ways); the channel is what separates them.

ChatGPT
chatgptchatgpt.comopenaichat.openai.comopenai.com
Perplexity
perplexityperplexity.ai
Claude
claudeclaude.aianthropic
Gemini
geminigemini.google.combardbard.google.com
Copilot
copilotcopilot.microsoft.com
Grok
grokgrok.com
Meta AI
meta.aimetaai
DeepSeek
deepseekdeepseek.com
You.com
you.com
Mistral
mistralmistral.ai

See also: What MTK Attribution captures · Recommended UTM parameters · Data source reference