How to Collect and Store UTM Parameter Data in HubSpot

How come you can't use UTM parameters in HubSpot?!?

HubSpot allows you to create Campaigns and assign each of them a unique utm_campaign parameter. You can also easily create tracking links with their Tracking UTM Builder. All good, but when it comes to finding the UTM data inside HubSpot, so you can use it for segmentation, workflows, or reports, you'll need to set some things up yourself. 

Yes, you got that right. HubSpot doesn't store UTM parameters in properties. They even strip UTM parameters from visited URLs in contact records. I've learned this the hard way. Don't ask! Because of this, list and workflows using the Page view filter may not pull in the contacts you're expecting.

There are two differences in the way that Page view filters search for contacts:

  • If you use UTM parameters in a Contact has visited URL containing the filter, the list or workflow will include the UTM parameters in its search. Because HubSpot strips UTM parameters from visited URLs in contact records, contacts who have visited the page with UTM parameters will not be pulled into the list or workflow.
  • If you use UTM parameters in a Contact has visited the exact URL filter, the list or workflow will not include the UTM parameters in its search. Contacts who have visited the page with or without UTM parameters will be pulled into the list or workflow. 
More details about this from HubSpot in this help article.

Having said that, let me show you how you can set up UTM parameters in HubSpot and even use them for creating marketing channel/campaign attribution reports. It works like a charm once you set it up.

hubspot utm parameters

 1. Create custom Hubspot UTM properties 

Start with creating the UTM properties you need in Hubspot. I suggest that you create a separate Group under properties and call it "UTM Tracking".

You'll want to create HubSpot properties for the 4 standard UTM parameters:

  • utm_campaign
  • utm_source
  • utm_medium
  • utm_term

To do so, in HubSpot click on Settings -> Properties -> Create a property under Contact Properties.

The “Internal Name” of the HubSpot property should be all lowercase to match the URL parameter name in the URL. Don't forget to tick: "Use in Forms". It's important for the next step.

hubspot utm campaign

It should look like this when you’re done with creating all the properties.

hubspot utm properties

 2. Collect and store UTM parameter information in your Hubspot properties 

Now that you have the UTM properties in place, you need to collect data in them. Doing that is also not straight forward in Hubspot. I only learned this after a lot of research and plenty of talks with the HubSpot customer support. 

To populate the properties you just created with real-life UTM data, you need to add them as hidden fields to your HubSpot forms. Yes, it's magic! To do that, just edit the form you're using, add your UTM fields and switch them to hidden.

Your form will look like this.

hubspot form hidden utm parameters


Make sure that you test the whole thing to see if the UTM parameters are properly saved in your custom properties when someone submits your form.

 3. Use UTM parameters in your HubSpot reports 

Create a HubSpot custom report using the custom properties you created in the previous steps. You can match UTM parameters with revenue, or use the "Count of contacts" metric to see how many leads a specific channel/campaign generated for you.

Here's how the conditions for such a report will look like. If you want to collect data that helps you calculate ROI for your campaigns, you can just match UTM data with lifetime revenue. You'll need to ask your development team to create and automatically sync such field in Hubspot.

utm reports in hubspot











Comments