The key aspect of becoming a great marketer is to be able to measure your success and measure your impact. No matter which indicator you use, you want to prove to your boss (and company) that you are worth it.
You deserve the budget—and maybe more—and you should spend your time on effective marketing activities. Building UTM codes that track the success of your campaign is the best way to prove this.
In this blog post, you will learn what UTM codes are, how to use them, and how to build them in both Google Analytics and HubSpot.
UTM (Urchin Tracking Module) code is a text fragment added to the end of a URL to help you track the source of website traffic when a user clicks a link to this URL. Marketers customize this text to match the web page linked by this URL in order to attribute the success of the campaign to specific content.
UTM codes are also called UTM parameters (or tracking tags) because they can help you “track” website traffic from the source.
Now, you may be thinking, “Ginny, I have HubSpot, so I already know whether my website traffic comes from Google, email, social media, and similar marketing channels. What does the UTM code tell me I don’t know yet?”
HubSpot Marketing Hub provides you with these high-level traffic sources, but UTM can also help you gain insight into specific pages and posts Within These traffic sources.
UTM code example
For example, if you promote an event on social media, you will know how much traffic comes from social media.
However, building a UTM code can tell you how much traffic comes from Facebook or even a specific Postal On Facebook.
Here is an example of a URL with its own UTM code highlighted in orange at the end of the following URL:
In the example above, you are saying that once the person who clicks on this link brings traffic, the traffic should be attributed to Facebook. “Media” is social media, and “source” is Facebook.
Adding these code snippets after the question mark above will not affect anything on the page-it just lets your analytics program know that someone arrives as part of a specific campaign through a source in the entire marketing channel.
UTM tracking needs to add a UTM code (a piece of code) at the end of the URL to track the effectiveness of marketing activities and content, as well as the source of website traffic.
UTM tracking best practices
Here are some best practices to keep in mind when creating and using UTM tracking URLs:
- Make your URLs and links consistent, clean, and easy to read (you can create a standard for link tag/UTM parameter guidelines to ensure consistency here).
- Keep a list of your UTM links so everyone on the team knows which tag links currently exist.
- Connect UTM tracking to your CRM (such as HubSpot) to gain insight into your bottom line.
- Be clear about your URL UTM parameters so that your label clearly states what you want to track and where.
- Stick to all lowercase or uppercase-UTM codes are case sensitive.
- Keep the name short but descriptive (e.g. “United States” and “United States”).
UTM parameter examples and use cases
The UTM code can track the medium and the source in that medium. Where it becomes more flexible is the language you use to describe the source. Maybe you want to attribute your website traffic to the social network, the type of content, or even the exact name of the ad on the network.
Here are five things you can track with UTM codes and why you can track them:
Activity-based tracking tags group all content of an activity in the analysis. The sample UTM code below will help you attribute your website traffic to links placed as part of your hosted 20% discount promotion.
Example: utm_campaign=20% promotion code
Origin-based URL parameters can tell you which website is sending you traffic. You can add the sample code below to every link you post to your Facebook page to help you track all traffic from Facebook.
This type of tracking tag informs you of the media where the link you are following is located. You can use the sample UTM code below to track all traffic from social media (rather than other media such as email).
Example: utm_medium=Social media
4. Content snippets
This type of UTM code is used to track specific types of content from common sources and media to the same destination.
It is usually used for pay-per-click (PPC) activities or to have two identical links on the same page, as shown in the sample UTM code below.
Example: utm_content=sidebarlink or utm_content=headerlink
Term or keyword-based tracking codes identify the keywords you paid for in PPC ads. If you pay for a Google Ads campaign that ranks under the keyword “marketing software”, you can add the following UTM code to the end of the link you submit to Google for this ad.
Example: utm_term=marketing + software
The best part of UTM parameters is that you can make any combination of these codes you like-use the minimum (activity, source and medium) to track all your links, or use all of them to get super specific about your tracking .
Obviously, you can combine UTM parameters in a variety of ways:
- Track the success of certain marketing plans.
- Understand the effectiveness of your social channels to promote your content and when your followers promote your content.
- Measure the effectiveness of guest posting recommended traffic.
- Track the same content across multiple marketing channels.
- See where most people click on your internal links in blog posts.
Okay, so you use UTM codes… but how exactly do you set them up? It’s easy.
The following are instructions for setting and measuring UTM parameters in Google Analytics and HubSpot.
How to build UTM code in Google Analytics
Here are the steps involved in building UTM code in Google Analytics.
1. Open Google’s Campaign URL Builder.
You can create three different types of tracking labels in Google, two of which can help you track the traffic of new apps in the app market. You will use the Google Analytics Campaign URL Builder — the third option in this list.
2. Fill in each link attribute in the form below.
Visit the page linked above and click the link to view this URL builder. Then, you will see the UTM builder as shown below. Add URL, marketing activity, source and medium information to their respective boxes.
3. Use links in marketing activities.
If you want to shorten it, you need a tool like bit.ly… or if you are a HubSpot customer, you just need to use HubSpot’s URL Builder.
4. Measure your success.
If you have set up Google Analytics for your website, Google will automatically track incoming campaigns. Just like in HubSpot, you can access them under “Audience”, “Source” and “Campaign.” Click each campaign to view the source and medium.
That’s it-you will set up and run the custom tracking code in no time! In a few weeks, you will be able to justify your needs, because you will have the right metrics available.
How to build UTM code in HubSpot
The following is how to build UTM code in HubSpot.
1. Navigate to your analysis tool.
In your Marketing Hub dashboard, select “Reports” on the top navigation bar. Then select “Analysis Tool” in the drop-down menu, as shown in the figure below.
2. Open the tracking URL builder.
In the analysis tool menu that appears, look at the bottom right corner. You will see the “Tracking URL Generator” option. Click this option at the bottom of the page, as shown in the red box below.
3. Open the tracking URL form to create a new UTM code.
Whenever you create an online marketing campaign that contains at least one UTM code, you will see this marketing campaign on the page shown below.
This page outlines the source, medium, duration, content, and creation date of the tracking label, which you can see at the bottom of the screenshot below. Click “Create Tracking URL” in the upper right corner.
4. Fill in each attribute of your UTM code and click “Create”.
In the form that appears, fill in the URL, marketing activity, source, and medium fields. If you want to add content and terms, you can add them in the two fields at the bottom of this form. When finished, you will see an orange “Create” button available at the bottom.
Click it and HubSpot will record your UTM code as a new activity, and this link will be ready to be included on any webpage you want to track traffic.
5. Use shortened links in marketing activities.
6. Measure your success.
You can track your UTM parameters in the traffic analysis dashboard under “Other marketing activities” as shown below. Click on individual campaigns to segment source and medium.
As you can see in the second image below, the name of the campaign is shown on the left (based on the text in the UTM code you created) and from the people who used each URL to reach your campaign’s main page Of traffic.
Start creating UTM tracking URL
Use the above steps, best practices, and tools to start creating and using UTM tracking URLs so that you can track the effectiveness of marketing campaigns and content.
Editor’s note: This article was originally published in September 2013 and has been updated to be comprehensive.