Source attribution that works with your existing forms

SourceTag is one script on your site. It works out where each visit came from (Google Ads, Meta, LinkedIn, Microsoft Ads, organic search, social, a referral), sorts it into a channel, and writes that into hidden fields on your forms. There's no dashboard you have to keep checking. The data goes wherever your forms already go.

Two touchpoints

First click and last click

Every submission carries two sets of fields: the visit that first brought them to your site, and the visit that brought them back to fill in the form. You get both, so you don't have to pick an attribution model and argue about it later.

  • First visit is locked on day one
  • Last click updates on each return visit
  • Both included in every form submission
First and last click attribution data in a CRM
Configurable channel rules editor

Your rules, not ours

11 configurable channels

Visits are sorted by rules you can see and edit. Start with our eleven defaults, then reorder them, switch some off, widen the matching, or add channels of your own.

If our definition of "Paid Social" does not match yours, change it.

EmailAffiliatesPaid SocialPaid SearchDisplayPaid VideoOther CampaignsOrganic SocialOrganic SearchReferralDirect

Smart fields

Smart fields that adapt to each channel

Four fields per touch change meaning depending on the channel. A Google Ads lead gets campaign, keyword and ad variation. An organic search lead gets the search engine and the page they landed on. You don't set any of that up.

If you want more, there are 20-odd optional fields: raw UTMs, a click ID per platform, visit counts, days to convert, and any URL parameter you name.

See the full field reference →
Smart fields adapt to each marketing channel
Click ID capture fields

Click IDs from the ad platforms

Click ID capture

Google Ads (gclid), Meta (fbclid), Microsoft Ads (msclkid), TikTok (ttclid), plus gbraid and wbraid for app campaigns. SourceTag captures these automatically and includes them in form submissions.

Have them combined into one field per touch or split out per platform, whichever suits your CRM.

Form builders

Works with any form builder

Gravity Forms, Contact Form 7, WPForms, HubSpot Forms, Typeform, JotForm, Elementor, Formstack, Tally, Fillout, and more. If it renders an HTML form, SourceTag can populate it.

The script finds forms as they appear on the page, including ones loaded later by AJAX or inside a popup, and it gets on fine with React. Most form builders need no configuration at all.

Compatible with form builders

Data fields

20+ data fields in every submission

Channel, source, campaign, keyword, ad content, landing page, click IDs, visit count, days to conversion, device type, and custom URL parameters. All captured automatically and sent with the form.

Attribution

Channel, source, campaign, keyword, ad content, landing page. First click and last click.

Click IDs

gclid, fbclid, msclkid, ttclid, gbraid, wbraid. Combined or individual fields per platform.

Visitor context

Visit count, days to conversion, device type, submission page, referrer domain.

Long sales cycles

400-day cookie persistence

Safari and privacy-focused browsers (Brave, all iOS browsers) limit JavaScript cookies to 7 days. If your leads take weeks to make up their mind, that's the attribution gone before they come back.

The SourceTag WordPress plugin sets cookies via HTTP headers, which these browsers allow for up to 400 days. For non-WordPress sites (Webflow, Squarespace, Framer), a Cloudflare Worker provides the same persistence.

400-day cookie persistence vs 7-day limit
Search engine and social network recognition

It knows where traffic comes from

80+ search engines, 70+ social networks

Google country variants, Bing, DuckDuckGo, Yandex, Baidu, regional engines. Facebook, Instagram, LinkedIn, X, TikTok, Bluesky, Threads, Reddit, and dozens more.

We keep the list current. When a new platform starts sending traffic, we add it and your script picks it up on its next rebuild.

For developers

JavaScript API

For single-page apps, social logins and anything without a normal form, read the data from JavaScript and send it wherever you like: a chat widget, your analytics, your own API.

const fc = window.__sourcetag.getFC();
const lc = window.__sourcetag.getLC();

Frequently asked questions

Start with one form.

The trial is 14 days and doesn't need a card.