Data source reference
Every value MTK Attribution can capture, what it means, and exactly what it looks for on the page. Use this to verify your field map and to spot issues — if a value arrives empty or wrong, the entry here tells you which signal it depends on.
How it works
- First vs last touch. Every touch dimension is captured twice.
first.*is frozen the very first time someone arrives and never changes;last.*refreshes at the start of each new session, so internal navigation can't degrade it. - The field map. Each row in Dashboard → license → Tag config maps a HTML Name (the left side, e.g.
mtk_first_source) to a data source (the right side, the expressions on this page). - Delivery. On page load the resolved values are pushed to the
mtk_attributiondataLayer event, keyed by each HTML Name, and written into any matching hidden form field (by name, or via a[mtk:…]token).
Query sources
Touch dimensions parsed from the URL query string (UTMs) and the referrer. Available as both first.* and last.*.
first.channel / last.channelThe normalized traffic grouping — Direct, Paid Search, Paid Social, Organic Search, Organic Social, Email, Referral, or Campaign. This is derived, not a raw parameter: the engine classifies each visit from its click IDs, utm_medium, utm_source, and referrer (see the “How MTK Attribution categorizes” page for the exact rules).
first.source / last.sourceThe platform or site behind the visit — utm_source (title-cased) when present, otherwise inferred from the referrer domain (Google, Facebook, LinkedIn, …), otherwise “Direct”.
first.medium / last.mediumThe raw utm_medium query value, exactly as passed (e.g. cpc, email, referral, paid_social). Channel is the grouping derived from it.
first.campaign / last.campaignThe utm_campaign query value.
first.term / last.termThe utm_term query value — Google Ads’ {keyword}.
first.content / last.contentThe utm_content query value — Google Ads’ {creative}.
first.ad_placement / last.ad_placementThe utm_placement query value — the ad placement, when your tracking template passes it.
Legacy aliases: first.placement / last.placement — old tags keep resolving.
first.landing_page / last.landing_pageThe landing-page path only — window.location.pathname (e.g. /pricing). No query string.
Legacy aliases: first.landing / last.landing — old tags keep resolving.
first.landing_page_group / last.landing_page_groupThe first path segment of the landing-page path (e.g. “blog” for /blog/my-post) — groups landings by site section. A top-level page like /pricing yields “pricing”; empty only when the visitor lands on the homepage (/).
first.query / last.queryThe landing-page query string — window.location.search (e.g. ?utm_source=google&utm_medium=cpc), including the leading “?”. Holds the raw UTMs and click-id params exactly as they arrived.
Legacy aliases: first.landing_query / last.landing_query.
first.referrer / last.referrerThe full referring URL of the visit that started the touch — document.referrer captured at the session’s first page. Empty on direct arrivals (typed URL, bookmark).
Cookies & Click IDs
Ad-platform click identifiers and Meta’s cookies — the raw keys used for Conversions API matching and offline conversion import. For Google and Microsoft, reach for last_paid.*: it holds the click ID of the most recent PAID touch and stays put through every direct or organic session that follows, so a conversion weeks after the ad click still has an ID to import against. The per-touch first.* / last.* forms are also available, but last.* empties the moment a visitor returns direct. Cookies and param: values are read live when the tag resolves.
last_paid.gclidGoogle Ads click ID of the most recent PAID touch. Sticky — it survives any number of direct or organic sessions afterward, so a conversion weeks after the ad click still carries the gclid for offline conversion import. Empty when the journey never had a paid touch.
first.gclid / last.gclidGoogle Ads click ID, read from the gclid URL query parameter.
last_paid.gbraidGoogle’s iOS web-to-app click ID from the most recent PAID touch, kept for as long as the journey runs — the gbraid counterpart to last_paid.gclid.
first.gbraid / last.gbraidGoogle’s iOS web-to-app click ID, from the gbraid URL query parameter.
last_paid.wbraidGoogle’s iOS app-to-web click ID from the most recent PAID touch, kept for as long as the journey runs — the wbraid counterpart to last_paid.gclid.
first.wbraid / last.wbraidGoogle’s iOS app-to-web click ID, from the wbraid URL query parameter.
last_paid.msclkidMicrosoft / Bing Ads click ID of the most recent PAID touch, kept for as long as the journey runs — for Microsoft offline conversion import.
first.msclkid / last.msclkidMicrosoft / Bing Ads click ID, from the msclkid URL query parameter. Its presence also classifies the visit as Paid Search / Bing.
param:fbclidRead live from the fbclid URL parameter on the current page. Also captured per-touch as first.fbclid / last.fbclid.
last_paid.fbclidThe fbclid of the most recent PAID Meta touch. Narrower than last.fbclid on purpose: Meta appends fbclid to organic links too, and a bare fbclid is classified Organic Social, so it never reaches this record. For Conversions API matching use mtk_fbclid (param:fbclid) and mtk_fbc (cookie:_fbc) instead.
first.ttclid / last.ttclidTikTok click ID, from the ttclid URL parameter. Its presence classifies the visit as Paid Social / TikTok.
last_paid.ttclidThe ttclid of the most recent PAID TikTok touch, kept for as long as the journey runs.
cookie:_fbcRead live from the browser’s _fbc cookie — Meta’s click identifier, used for Conversions API matching.
cookie:_fbpRead live from the browser’s _fbp cookie — Meta’s browser / pixel identifier, used for Conversions API matching.
Insights
Values derived from the multi-touch journey and the moment of conversion — counts, the journey path, and conversion timing.
journey.stringThe full multi-touch journey as text, e.g. “Paid Social/Facebook > Organic Search/Google > Direct/Direct”. One entry per session.
Legacy alias: path.string — old tags keep resolving.
journey.jsonThe same path as a JSON array — each entry carries the touch timestamp, channel, source, and campaign — for parsing downstream.
Legacy alias: path.json.
session.countThe number of sessions (touchpoints) recorded in the journey.
Legacy alias: path.count.
pageview.countEvery page load across the whole journey, all sessions.
Legacy alias: pageview_count.
last.paid_touchThe most recent PAID touch (Paid Search / Paid Social) as “channel/source”, e.g. “Paid Social/Facebook”. Sticky — kept outside the capped path, so it survives arbitrarily long journeys. Empty when the journey never had a paid touch. Individual dimensions: last_paid.channel, last_paid.source, last_paid.campaign; last_paid.time is that touch’s moment as Unix seconds for attribution-window math.
Legacy alias: last_paid.string — old tags keep resolving.
time_since_last_paid_touchLast paid touch → submit, human-readable (e.g. “2d 6h”). Empty when the journey never had a paid touch.
Legacy alias: time_since_paid.
paid_touch_countHow many paid touches the journey had — “0” when none. The frequency picture behind a conversion.
time_to_conversionFirst touch → now, human-readable (e.g. “12d 4h”). Handy for your own reporting.
conversion_unixSubmit time as Unix seconds — drops straight into Meta CAPI event_time. Timezone-less by nature.
Legacy alias: conversion_timestamp.
conversion_datetimeSubmit time as “yyyy-MM-dd HH:mm:ss±HH:mm” — the format Google Ads offline conversion import expects. Rendered in the license's configured timezone when set (offset included either way).
custom_conversion_timeSubmit time in the shape configured under “Custom conversion time” — MM/DD/YYYY or DD/MM/YYYY (month-name and hours/minutes/seconds toggles), Unix seconds, or the Google datetime format, with an optional per-field timezone override. Built for CRM and spreadsheet imports.
page.pathThe path of the page the form was submitted on, without the query string — resolved at submit, so it's the conversion page rather than the landing page.
page.urlThe page the form was submitted on, as origin + path — no query string, since the landing-page, UTM, and click-ID fields already carry the parameters. Resolved at submit, so it's the conversion page rather than the landing page.
page.titleThe title of the page the form was submitted on, as the browser tab shows it.
referrerThe raw document.referrer string for the current page.
attribution_summaryEvery OTHER mapped field, resolved and joined into one “name: value | name: value” string — for CRMs that only give you a single field. Empty values are skipped, and a field mapped to the summary itself is excluded.
Legacy alias: summary.
Other / custom resolvers
Generic prefixes for pulling in anything the built-in dimensions don’t cover. NAME / KEY / VALUE are placeholders you replace.
param:NAMEReads any live URL query parameter on the current page, e.g. param:gclid or param:utm_id.
cookie:NAMEReads any browser cookie by name, e.g. cookie:_ga.
dl:KEYReads a key from the GTM dataLayer (most recent value wins).
const:VALUEAlways resolves to the fixed literal you specify, e.g. const:paid_media.
datetime:FORMATThe conversion moment, formatted your way for a CRM field — e.g. datetime:MM/dd/yyyy hh:mm a → “08/06/2026 09:14 AM”. Tokens: yyyy yy MMM MM dd HH hh mm ss a; everything else passes through. Rendered in the license's configured timezone (else the visitor's clock). For Meta CAPI or Google offline import, use conversion_unix / conversion_datetime instead — those are purpose-built payloads.
func:NAMECalls a resolver function registered on the tag — for values none of the built-ins cover.
Values arriving empty or unexpected? Start with Troubleshooting, or check the field map in Dashboard → license → Tag config.