Where Marketers Go to Grow

Search HubSpot's Blogs

Start typing...

Press return/enter to start your search


Join 475,000 Fellow Marketers

Get expert marketing tips straight to your inbox, and become a better marketer. Subscribe to the Marketing Blog below.

August 26, 2014 // 4:50 PM

Marketing Tools

What Are UTM Tracking Codes? [FAQs] (Clone)

Written by Ginny Mineo | @

measure_your_marketingOne crucial aspect of being a great marketer is being able to measure your success. No matter which metrics you use, you want to prove to your boss and the company at large that you're worth your salt. You deserve your budget -- and maybe need more of it. You deserve to hire another person to supplement your marketing activities. You deserve to dedicate time to the marketing activities that work. 

But actually measuring the impact of can be kind of tricky without the right tools. Sure, you know that Twitter drives a certain percentage of traffic to your website ... but do you know that your company's tweets were the ones driving those visits? Or that your specific guest post drove actual leads and customers to your website? Luckily, you can prove all of that with a few special codes added to the end of your URLs: They are called UTM codes. 

What Are UTM Codes?

Also known as UTM parameters, UTM codes are little snippets of text added to the end of your URL to help you track the success of your content on the web. An example of UTM codes is highlighted in the URL below in orange:

http://blog.hubspot.com/9-reasons-you-cant-resist-list?utm_campaign=blogpost &utm_medium=social&utm_source=facebook

Adding the snippets of code after the question mark doesn't affect anything on the page -- it just lets your analytics program know that someone arrived through a certain source or overall marketing channel as part of a certain campaign. Here are the five things you can track with UTM codes:

  1. Campaign: Groups all of the content from one campaign in your analytics. 
    • Ex: utm_campaign=20percentpromocode
  2. Source: Which website is sending you traffic.
    • Ex: utm_source=Facebook
  3. Medium: The type of marketing medium that the link is featured in.
    • Ex: utm_medium=socialmedia
  4. Content: Used to track the different types of content that point to the same URL from the same campaign, source, and medium codes. Often used in PPC or with two identical links on the same page.
    • Ex: utm_content=sidebarlink or utm_content=headerlink
  5. Term: Used to identify the keywords you've paid for in a PPC ad. 
    • Ex: utm_term=marketing+software

The best part about UTM parameters is that you can make any combination you like of these code -- use the bare minimum (campaign, source, and medium) to track all of your links, or use all of them to get super specific about your tracking. Here are a couple ways you could use a combination of UTM parameters in lots of ways:

  • Track the success of certain marketing initiatives.
  • See how well your social channels promote your content versus when your followers promote your content.
  • Measure the effectiveness of guest posting referral traffic. 
  • Track the same piece of content across multiple marketing channels.
  • See where most people click on your internal links in a blog post. 

Okay, so you're on board with UTM codes ... but how the heck do you set them up? It's easy. Below are instructions for setting up and measuring UTM parameters in HubSpot and Google Analytics.

How to Track UTM Codes in HubSpot

1) Set up UTM Codes

In your dashboard, select 'Reports,' then 'Reports Home.'


In the 'Reports Home,' click 'Tracking URL Builder' at the bottom right of your page.


Click 'Create New Tracking URL' in the top right corner.


Fill in the URL, Campaign, Source, and Medium fields. If you'd like to add Content and Term, click 'More Options' after the Medium field. When you're done, click 'Generate.'


2) Use the Shortened Link in Your Marketing


3) Measure Your Success

You can track your UTM parameters in your Sources Report under 'Other Campaigns.' Click on the individual campaign to break down the source and medium.


How to Track UTM Codes in Google Analytics

1) Set up UTM Codes

Using Google URL Builder, add the URL, Campaign, Source, and Medium information into the selected boxes.


2) Use the Link in Your Marketing

If you'd like to shorten it, you'll need a tool like bitly ... or just use HubSpot's URL Builder if you're a HubSpot customer.


3) Measure Your Success

If you already have Google Analytics set up for your site, Google will automatically track incoming campaigns. Like in HubSpot, you can access them under 'Audience,' then 'Sources,' then 'Campaigns.' Click on each campaign to view the source and medium.


And that's it -- you'll have custom tracking codes set up and running in no time! In a few weeks, you'll be able to make a case for what you need because you'll have the right metrics available.

How will you use UTM codes in your marketing?

Image credit: geishaboy500

New Call-to-Action


Topics: Analytics

Subscribe to HubSpot's Marketing Blog

Join 475,000+ fellow marketers! Get HubSpot's latest marketing articles straight to your inbox. Enter your email address below:


Sorry we missed you! We close comments for older posts, but we still want to hear from you. Tweet us @HubSpot to continue the discussion.

subscribe to hubspot's marketing blog
get the free HubSpot CRM now