Guide

UTM Tracking & Attribution

How to use the protagx UTM Builder, why it matters, and how to wire everything
into HubSpot so every lead carries its source from click to closed deal.

Why UTM tracking matters

Most marketing teams send traffic from multiple channels — LinkedIn ads, email campaigns, organic posts, Google Ads — but have no reliable way to know which channel actually generated a pipeline opportunity. Without UTM parameters, every visitor who lands on your website looks the same inside your CRM.

UTM tracking closes that gap. By appending a short set of tags to every link you publish, you give your CRM a permanent record of where each contact came from, which campaign brought them, and which specific asset they clicked. That record follows the contact through the pipeline — from first touch all the way to closed-won deal.

The core insight: a contact without a lead source is a dead end for attribution. A contact with UTM data attached is a data point that feeds every future campaign decision.

With clean UTM data flowing into your CRM you can answer questions that are otherwise impossible: Is LinkedIn Ads generating deals, or just contacts? Is your outbound email sequence producing booked meetings at a better rate than paid search? Which campaign produced the most pipeline value this quarter?

None of that is measurable without consistent, disciplined UTM tagging on every link, in every channel, from day one.

How it works end-to-end

The system has three moving parts that work together automatically once configured:

Tagged URL You publish a link with UTM parameters appended
Tracking code HubSpot reads the UTMs from the browser on page load
Contact created Visitor submits a form — UTM values are stored on the record
Workflow fires Automation reads UTMs and sets Lead Source property
Attribution visible Source data appears on contact, deal, and dashboard

The HubSpot tracking code is the bridge between the URL in your campaign and the contact record in your CRM. It reads UTM parameters automatically — but only if they are present and correctly formatted on the link that drove the visit.

Anatomy of a UTM URL

A tagged URL is your normal destination URL with a query string appended. Each parameter answers one specific attribution question:

https://yourdomain.com/page?utm_source=linkedin&utm_medium=paid-social&utm_campaign=product-launch-q2&utm_content=hero-cta-v1
Parameter Required Answers the question Example
utm_sourceYesWhich platform sent the traffic?linkedin, google, mailerlite
utm_mediumYesWhat type of channel was it?paid-social, email, organic
utm_campaignYesWhich campaign does this belong to?product-launch-q2
utm_contentOptionalWhich specific ad, CTA, or step?hero-cta-v1, step-2
utm_termOptionalWhich paid keyword triggered this?crm-software-uk
utm_source, utm_medium, and utm_campaign are all required for HubSpot's attribution workflow to classify the lead source correctly. Missing any one of the three means the contact will fall into the "Other / Unknown" bucket.

Naming rules — non-negotiable

UTM values are case-sensitive and exact-match. A single inconsistency creates a phantom source in your reports and silently breaks attribution for every contact that comes through that channel.

Lowercase only
utm_source=LinkedIn and utm_source=linkedin are two different sources in HubSpot. Always use lowercase.
Hyphens, not spaces
Spaces encode as %20 and produce unreadable URLs. Use hyphens to separate words: product-launch-q2.
No special characters
Avoid &, ?, #, or = inside parameter values. These break URL parsing entirely.
One canonical name per campaign
Decide on a campaign name and use it identically across every channel. Inconsistency fragments your attribution data across multiple rows.
The UTM Builder enforces these rules automatically. Dropdown fields for utm_source and utm_medium prevent free-text errors on the most critical parameters. The validation bar flags uppercase characters and spaces in utm_campaign before you copy the URL.

Standard channel taxonomy

Use these values consistently across all channels. The quick-fill presets in the UTM Builder are pre-loaded with this exact taxonomy.

Channel utm_source utm_medium utm_campaign pattern utm_content
LinkedIn Adslinkedinpaid-social[product]-[audience]-[quarter][ad-variant]
LinkedIn Organiclinkedinorganic-social[topic]-[month]
HubSpot Sequencehubspot-sequencesemail[sequence-name]step-[n]
Broadcast Emailmailerliteemail[newsletter-name]-[month-year]cta-[position]
Google Adsgooglepaid-search[ad-campaign-name][ad-group]
Website / Organicwebsiteorganic[page-slug]-[cta][position]
Instagram Adsinstagrampaid-social[campaign]-[quarter][creative-id]
Referral partnerreferralreferral[partner-name]
HubSpot Sequences note: HubSpot does not auto-append UTMs to links inside sequence steps. You must manually add UTM parameters to every CTA link inside each sequence email step. Use the UTM Builder and paste the tagged link directly into the sequence editor.

HubSpot setup — 3 prerequisites

Step 1 of 3

Before UTM data can flow into your CRM, three things must be in place. These are one-time configuration tasks that take less than an hour total.

  • 1
    Install the HubSpot tracking code on every page
    Go to Settings → Account Management → Tracking & Analytics → Tracking Code. Copy the embed snippet and place it in the <head> of every page on your website — or in the global header component if using a CMS.

    QA check: Visit yoursite.com?utm_source=test&utm_medium=test, submit a test form, and confirm the contact record shows UTM properties populated within a few minutes.
  • 2
    Confirm HubSpot's built-in UTM contact properties are visible
    Go to Settings → Properties → Contact Properties → filter "Analytics". You should see: utm_source, utm_medium, utm_campaign, utm_content, utm_term, hs_analytics_source, hs_latest_source, and their drill-down variants.

    These are populated automatically by the tracking code — no workflow needed. They exist natively in every HubSpot portal.
  • 3
    Create a custom "Lead Source" contact property
    Go to Settings → Properties → Contact Properties → Create property. Set field type to Dropdown select. Add these values: LinkedIn Ads, LinkedIn Organic, Outbound Email Sequence, Broadcast Email, Google Ads, Organic / SEO, Website Direct, Referral, Event / Conference, Other.

    This property will be written by your automation workflow (Step 2 below) and is the single field used across contacts, deals, and reports.

Automation workflow — auto-populate Lead Source

Step 2 of 3

This workflow reads the UTM values stored on a new contact record and writes the correct Lead Source value. It runs once per contact, at creation, and requires no manual intervention after setup.

Automation → Workflows → Create workflow → Contact-based → Start from scratch

Set the enrollment trigger to Contact is created. Disable re-enrollment — this should fire once only. Then add the following if/then branches:

LinkedIn Ads
conditionutm_source = linkedin AND utm_medium = paid-social
actionSet Lead Source = LinkedIn Ads
LinkedIn Organic
conditionutm_source = linkedin AND utm_medium = organic-social
actionSet Lead Source = LinkedIn Organic
Outbound Email Sequence
conditionutm_medium = email AND utm_source = hubspot-sequences
actionSet Lead Source = Outbound Email Sequence
Broadcast Email
conditionutm_medium = email AND utm_source = mailerlite
actionSet Lead Source = Broadcast Email
Google Ads
conditionutm_source = google AND utm_medium = paid-search
actionSet Lead Source = Google Ads
Organic / SEO
conditionhs_analytics_source = Organic Search OR utm_medium = organic
actionSet Lead Source = Organic / SEO
Fallbackalways last
conditionLead Source is unknown / empty
actionSet Lead Source = Other

Make attribution visible in the CRM

Step 3 of 3

UTM data captured on a contact record needs to be surfaced where your team actually works — on the contact sidebar, on the deal card, and in the pipeline board view.

  • A
    Add UTM properties to the contact sidebar
    Open any contact → click the pencil/customise layout icon → Add property. Add: Lead Source, Original Source, UTM Campaign, UTM Medium, UTM Source, Latest Source. Group them under a section labelled "Attribution" so they appear as a single scannable block.
  • B
    Copy Lead Source to deal records via a second workflow
    Create a second workflow: trigger = Deal is created. Action = copy associated contact's Lead Source → Deal's Lead Source property (which you create as a matching dropdown on deal records).

    This is necessary because UTM contact properties do not automatically propagate to associated deals. Once this workflow is live, every new deal carries its lead source independently.
  • C
    Add Lead Source as a deal card property in pipeline view
    Go to CRM → Deals → Board view → Edit cards → Add property → Lead Source. This surfaces the source on every deal card in your pipeline board — making attribution visible without opening individual records.

Building an ROI attribution dashboard

Once lead source data is flowing cleanly into contacts and deals, you can build a dedicated attribution dashboard in HubSpot. Go to Reporting → Dashboards → Create dashboard → "Attribution & Lead Source" and add these five reports:

Report Type What it shows
Contacts by Lead SourceBar chartVolume of new contacts per channel, rolling 30 days
Deals created by Lead SourceBar chartPipeline count and deal value attributed per channel
Conversion rate by Lead SourceFunnel / tableContact → deal → closed-won rate per channel — the core ROI comparison
Contacts over time by Lead SourceLine chartWeek-on-week trend of each channel's contribution
Sequence engagementTablePer-sequence: enrolled, replied, meeting booked — email ROI at a glance
The conversion rate report is the one that matters most. A channel generating many contacts but few deals is a vanity metric. A channel generating fewer contacts but a high deal conversion rate is where budget should be concentrated.

QA checklist — verify before going live

Run through each of these checks after completing setup. Every item must pass before you can trust your attribution data.

  • Submit a test form from a UTM-tagged URL — confirm UTM properties appear on the contact record within 5 minutes
  • Confirm the Lead Source workflow fires and sets the correct value for at least 3 channel branches
  • Check that Lead Source appears in both the contact sidebar and the deal sidebar
  • Send a test sequence email with a UTM link, click it, submit a form — confirm Lead Source = Outbound Email Sequence
  • Confirm the Lead Source deal workflow fires and copies the value from contact to deal on creation
  • Confirm the attribution dashboard loads and shows data segmented by Lead Source
  • Test the UTM Builder tool — generate a URL, copy it, and verify it produces a correctly structured tagged link with no uppercase or spaces
Ready to build your first tagged URL?
Use the protagx UTM Builder to generate correctly formatted, validated campaign URLs in seconds — with quick-fill presets for every channel.
Open UTM Builder