How to track UTM parameters in Hubspot CRM

Learn how to track UTM parameters in Hubspot CRM so you can see exactly which marketing channels and campaigns are driving your leads, customers & revenue.

Last updated
Hubspot
TL:DR

Tracking UTM parameters in Hubspot CRM is straightforward with Attributer. You add a few hidden fields to your forms, Attributer automatically populates them with the UTM data each time someone fills out a form, and the values flow into Hubspot CRM alongside the lead's name and email. As a bonus, it also captures attribution data for leads from organic channels like Organic Search and Organic Social, where UTM parameters aren't present.

Do you know which marketing channels and campaigns are actually generating the leads and customers for your business? If you don't, it's likely you're investing in the wrong things and missing easy chances to grow.

The good news? There's a solution. By tracking UTM parameters in Hubspot CRM with each new lead, you can run reports that show exactly which channels, campaigns, and ads are driving real revenue (not just clicks).

In this article, we'll show you how to use Attributer to capture UTM parameters and pass them into Hubspot CRM. We'll also share some example reports you can run once it's all set up.

4 steps for capturing UTM parameters in Hubspot CRM

Attributer makes it easy to track UTM parameters in Hubspot CRM. Here's how to set it up in 4 simple steps:

1. Add the Attributer code to your website

Add Code to Website

The first step is to sign up for a 14-day free trial of Attributer. Once you do, you'll get a small snippet of code to add to your website.

How you install the code depends on what platform your site is built on. If you're on WordPress, you can typically add it through your theme's settings panel or with a plugin like Insert Headers and Footers Code. On Webflow, Squarespace, and most other website builders, there's usually a "custom code" or "header/footer scripts" section in the site settings. If you're using Google Tag Manager, you can also add it through there.

2. Add hidden fields to your forms

Step 2

Next, you need to add some hidden fields to your lead-capture forms. These hidden fields aren't visible to your visitors, but Attributer uses them to write the UTM data into when a form is submitted.

Most form builders make this easy. Whether you're using Hubspot Forms, Gravity Forms, Webflow Forms, Wix, Jotform, or any other tool, you can typically drag a "Hidden Field" type into your form and configure it from there.

The six hidden fields you need to add to your forms are:

  • Channel
  • Channel Drilldown 1
  • Channel Drilldown 2
  • Channel Drilldown 3
  • Landing Page
  • Landing Page Group

3. Attributer automatically completes the hidden fields with UTM data

Step 5

With everything in place, Attributer will start tracking where each visitor on your website came from and writing that information into the hidden fields on your forms.

To make this concrete, imagine you're the marketing manager at an accounting firm. You're running Google Ads to attract small business owners looking for help with their tax returns.

If a potential client searches Google for "tax accountant Sydney", clicks one of your ads, and fills out the contact form on your website, Attributer would write the following details into the hidden fields:

  • Channel = Paid Search
  • Channel Drilldown 1 = Google
  • Channel Drilldown 2 = Tax Services Campaign
  • Channel Drilldown 3 = Small Business Accountant Sydney

On top of that, Attributer also captures the visitor's first landing page and the landing page group:

  • Landing Page = www.youraccountingfirm.com/services/tax-returns
  • Landing Page Group = /services

4. UTM parameters are passed into Hubspot CRM

Step 4

Finally, when the visitor submits the form, the UTM data Attributer wrote into the hidden fields gets passed into Hubspot CRM alongside the lead's name, email, phone number, and any other details they entered.

Once the data is in Hubspot, you can use it in a few different ways:

  • See it on each contact record so you instantly know where every lead came from
  • Build Hubspot reports that show how many leads, deals, and how much revenue each channel and campaign generated
  • Set up workflows that route leads to different sales reps based on the channel they came from
  • Use the data in your sales sequences and email marketing to personalise outreach

What is Attributer?

Essentially, Attributer is a small piece of code that lives on your website. When a visitor lands on your site, it analyses some technical details (similar to what Google Analytics looks at) to determine where they came from.

Based on that data, Attributer categorises each visitor into a series of channels (like Paid Search, Organic Search, Paid Social, etc.) and stores the information as a cookie in their browser.

Then, when that visitor fills out a form on your website, Attributer automatically writes the channel data into the hidden fields. So when the form is submitted, the attribution information flows into Hubspot CRM alongside the lead's name, email, and any other details.

Attributer was originally built by a B2B marketing consultant who saw his clients constantly struggling to figure out which channels were actually generating leads and customers (as opposed to just driving website visitors, which Google Analytics already shows).

Why using Attributer is better than capturing raw UTM parameters

There are a few different ways to capture UTM parameters in Hubspot CRM, including Hubspot's own built-in method. So why use Attributer?

The short answer is that it does a lot more than just capture raw UTM parameters. Let's take a closer look at the key things that set it apart:

1. Captures all traffic

Attributer captures attribution data for every lead that completes a form on your website, not just the ones from your paid advertising campaigns.

That means if a visitor arrives on your site via Organic Search, Organic Social, Direct, Referral, or any other channel where UTM parameters aren't present, Attributer will still capture and pass through information about where they came from.

So you'll see where every lead in Hubspot CRM came from, not just the ones from your paid campaigns.

2. Remembers the data as visitors browse your site

Most other methods for capturing UTM parameters only work if the visitor fills out a form on the same page they originally landed on. That's a problem, because in the real world that's rarely how people behave.

Imagine someone clicks one of your Google Ads and lands on a campaign-specific landing page. Once they've decided you might be a good fit, they navigate over to your Contact page to fill out a form there. Because the Contact page wasn't the page they landed on, the UTM parameters from the ad would be lost.

Attributer solves this by storing the UTM parameters as a cookie in the visitor's browser as soon as they land on your site. So no matter how many pages they browse (or even if they leave and come back later), the original UTM data still gets passed through into Hubspot when they eventually submit a form.

3. Works with dozens of form builders

Hubspot's built-in UTM tracking only works if you're using Hubspot Forms on your website. If you've got a contact form built with another tool, those leads won't have UTM parameters attached to them in Hubspot.

Attributer takes a different approach. It works with dozens of form builders, so you can capture UTM parameters regardless of what your website is built on or what form tool you're using.

It supports Gravity Forms, Jotform, Wix Forms, Webflow Forms, Squarespace Forms, and many more. You can see the full list on our Integrations page.

4. Captures Click ID's

In addition to UTM parameters, Attributer also captures the click IDs that ad platforms attach to each visit. That's the Google Click ID (GCLID), the Microsoft Click ID (MSCLKID), and the Facebook Click ID (FBCLID).

Once those click IDs are flowing into Hubspot CRM, you can send them back to the ad platform at key moments in your sales pipeline (like when a lead becomes a paying customer). The ad platform then sees the conversion against the original click and can optimise toward generating more of those.

This is far more useful than just tracking thank-you-page visits as conversions, because you're optimising toward actual paying customers rather than form submissions that might never convert.

5. Captures landing page data as well

Beyond channel data, Attributer also captures the specific landing page each visitor first arrived on, plus the landing page group (the subdirectory).

For example, if a visitor lands on yoursite.com/blog/best-tax-tips, Attributer would capture both the full URL and the landing page group (/blog).

This means you can run reports in Hubspot that show exactly which sections of your site (and even which individual blog posts) are driving leads and customers. Useful when you're trying to figure out what content is worth doubling down on.

4 example reports you can run when you capture UTM parameters in Hubspot CRM

With Attributer capturing UTM parameters and passing them into Hubspot CRM, you can run reports like the ones below to understand what's actually driving leads and revenue:

1. Leads by Channel

Leads By Channel (7)

Because Attributer captures attribution data for every lead (not just those from paid campaigns), you can run reports that break down how many leads you got each month by channel.

This gives you a clear view of where your leads are actually coming from. It also helps you spot which channels are worth investing more in vs. which ones are underperforming.

2. Leads by Facebook Ads Network

Leads By Facebook Ad Network

If you're running ads across Meta's various networks (Facebook, Instagram, Messenger, etc.), this report helps you see which network is generating the most leads.

That visibility lets you fine-tune your ad spend, putting more budget into the networks that are working and pulling back from the ones that aren't.

3. Customers by Google Ads campaign

Customers by Google Ads Campaign

This report shows how many actual paying customers you're acquiring each month from each of your Google Ads campaigns.

It's a powerful one because it goes beyond just measuring clicks or form fills. It tells you which campaigns are bringing in customers who actually convert, so you can shift budget into what's truly working.

4. Revenue by Keyword

Revenue By Keyword

If you include the keyword in the UTM parameters of your Google Ads (which you can easily do with tracking templates), you can run a report showing exactly how much revenue each keyword has generated.

That's useful in two ways. It tells you which keywords are worth bidding higher on in Google Ads, and it gives you a strong signal for which keywords to prioritise in your SEO efforts too.

How Harris Federal Law uses Attributer to know which Google Ads are actually winning new clients

Harris Federal Law Firm is a Washington D.C. legal practice that helps federal employees secure their benefits. They were running Google Ads to attract new clients and could see how many website visitors each campaign was generating in Google Analytics, but they had no way to tell how many of those visitors actually became paying clients.

That changed when they installed Attributer. Now whenever someone fills out a form on their website, Attributer writes all the campaign details (like campaign name, ad group, ad, and search term) into hidden fields, and that data is sent to their CRM with each new lead.

They quickly discovered that some of their display campaigns were generating lots of website visitors but very few paying clients. With that insight, they shifted budget into the search campaigns that were performing best. The result was more clients, better use of their ad spend, and confidence that every dollar was going to work in the right place.

"With Attributer we can see which campaigns are actually generating customers & revenue, rather than just website visitors. We were able to see that some of our campaigns were driving lots of visitors but few of them converted into leads and customers. Now we’re able to reinvest that budget into other campaigns that we can see are generating revenue."

Nick Harris Law Firm

Nick Child - Director of Marketing, Harris Federal Law Firm

Wrap up

If you've been wanting to know which marketing channels and campaigns are actually generating leads and customers for your business, capturing UTM parameters in Hubspot CRM with Attributer is a great way to do it.

It will pass the UTM data from your campaigns into Hubspot so you can run reports that show what's truly working. As a bonus, it also captures attribution data for leads coming from organic channels like Organic Search and Organic Social, where UTM parameters aren't present.

Best of all, it's free to get started, and setup usually takes less than 10 minutes.

Get Started For Free

It's free to get started with Attributer, and paid plans start at just $29 per month