Posts tagged "tracking"

What are UTM tracking codes

Let’s start with a definition.

A UTM tracking code is a snippet of text added to the end of a URL that helps track the performance of campaigns using Google Analytics. They can be used to differentiate how different channels, content and creatives in the same campaign are performing.

Anyone can create and use a UTM tracking code and you can use them in virtually any place where you can control the link back to your website.

When a person clicks on a link which includes a UTM code, the browser address bar will look something like this:

In order to get any value from using UTM codes, you need to use Google Analytics as this is the tool that captures and processes the data from your UTM codes.

What does UTM stand for?

The full form of UTM is Urchin Tracking Module. If this seems a bit random, it’s a legacy from a company that Google bought in 2005.

Many years ago, before Google Analytics, there was a website analytics tool used by big websites called Urchin. They developed a way for website owners to track the performance of their campaigns by appending a piece of code to the end of their links called the Urchin Tracking Module – or UTM for short.

In 2005 a company you may have heard of, Google, bought Urchin and what was Urchin Analytics became Google Analytics. For reasons not publicly known, but probably to ensure continuity with the large companies using Urchin, the UTM tracking feature was never renamed.

In some ways you could say that Urchin’s legacy lives on through UTM tracking.

What are UTM codes used for?

UTM codes are used by Google Analytics to help curate data from your campaigns.

From your Google Analytics account, you can see how much website traffic you got from a campaign and if you’ve got event tracking or conversion goals set up you can see how many leads or even revenue you’ve generated from a campaign.

Here we can see that I ran three campaigns (Free_Trial, New_Blog, Backlink) that have been picked up and tracked by Google after I tagged all links with UTM codes:

Ultimately, the aim of using UTM codes is to give you complete visibility into the performance of your campaigns and traffic sources so you can evaluate them on parameters like the volume of traffic they generated, the number of leads generated, the number of signups generated or how much revenue was generated.

When done correctly, you should have a granular view into the performance of a campaign and be able to make a decision on whether it was effective or not depending on the campaign goal.

You might find that although a campaign was successful overall, there were traffic sources such as Twitter which were less effective than another source, say Google Ads, in helping you reach your goal.

What do UTM tracking codes look like?

A UTM tracking code added to the end of a URL typically consists of three parts:

  • Source
  • Medium
  • Campaign

When put together, it looks like this:

Here’s the link in the image in plain text:

https://yourdomain.com?utm_source=SOURCE-NAME&utm_medium=MEDIUM-TYPE&utm_campaign=YOUR-CAMPAIGN

The text in bold are the parts that you need to edit so you can effectively track the campaign you are running.

You use the ampersand symbol ‘& to set where the parameter text ends and the new parameter begins.

You can use a UTM code even on links to sub-pages on your website, not just to the home page. You simply have to append all the tracking code starting from the question mark ‘?’. It will look like this:

https://yourdomain.com/product/product-feature/?utm_source=SOURCE-NAME&utm_medium=MEDIUM-TYPE&utm_campaign=YOUR-CAMPAIGN

There are three essential parameters of a UTM tracking code:

  • utm_source – where your link was placed (eg. Facebook, Google, Twitter, the name of a particular website, etc.)
  • utm_medium – the way in which the link has been delivered (eg. banner, email, ad, etc.)
  • utm_campaign – the name of the campaign you are running (eg. Product_Launch_2020)

There are also two optional parameters of a UTM tracking code which you can use to further identify the type of ad that was clicked on:

  • utm_content – useful when you have multiple links going to the same URL (eg. inline link, image link, CTA link)
  • utm_term – used in conjunction with Google Ads to let you know which search keyword triggered your ad to be shown

Let’s look at each parameter in more detail to see how they work together to help you build an effective tracking system for your campaign.

utm_source

This parameter tells Google Analytics where the traffic comes from. It’s the source of the traffic.

If your campaign is running on Facebook, then you might enter facebook as the source. If you are running an ad on the New York Times website, you might enter nytimes as the source. If your SDR team is sending out cold email outreach campaigns using Yesware or Outreach.io then you might use SDR as the source.

Here’s how I’d format a link to my site that I post on Facebook:

  • https://peterclaridge.com/?utm_source=facebook

Some popular source parameters might include:

  • facebook
  • linkedin
  • twitter
  • google
  • cpc
  • newsletter
  • SDR
  • hubspot
  • marketo
  • adroll
  • g2
  • collateral

Note: If you are buying an ad on a particular website, you might enter the name of that website in the source.

Here’s how the utm_source shows up in my Google Analytics account:

You can’t just use the utm_source parameter in your link and be done with it, you must also include the utm_medium parameter for it to be accurately tracked in Google Analytics.

utm_medium

Now the utm_medium parameter confuses even experienced marketers. What’s the difference between utm_source and utm_medium?

For example, if you send out an email newsletter to your customers using Mailchimp, is the medium a newsletter or email? Or is the utm_source the newsletter or is it Mailchimp?

The best way to think about it is to think about the method of delivery. How is your link being delivered to your audience so that they can click on it?

If you are running a remarketing campaign on the Google ad network, then the medium by which you are delivering your campaign for people to click on are graphical banners. In marketing-speak, this is a display campaign. Therefore, the utm_medium would be display.

Some popular utm_medium parameters that you might set include:

  • display
  • email
  • cpc
  • banner
  • video
  • popup
  • text
  • ad
  • social
  • pdf

You need to think about how the link is being delivered to the audience and set that as your medium.

Here’s how the utm_medium is displayed in my Google Analytics account for all the traffic that came to my site:

You can see “email” was my medium for three different traffic sources:

  • My email lead sequence (a lead sequence is used after a person downloads a lead magnet)
  • An email newsletter I send out to my email database
  • The personalized email outreach I do to try and build backlinks to my blog posts

utm_campaign

The utm_campaign helps you differentiate between all the campaigns you have run and are running.

When you’re running a digital campaign, whether it’s for a product launch or promoting your latest lead magnet or just building awareness, you’ll most likely be running the campaign across multiple channels – Google Ads, Facebook Ads, sending newsletters etc.

In some ways the utm_campaign parameter is the single most important tag because it ties together all the promotion you’re doing across sources and mediums.

utm_content

This is an optional parameter that you can choose to use or ignore. Google defines utm_content as a parameter that can help you differentiate between ads that point to the same URL

For example, if you have an email that includes links that are inline, an image linked to the same URL and a CTA button, you could use utm_content=text, utm_content=image, and utm_content=cta to differentiate between the three types of links. You’ll be able to tell whether your email subscribers are more likely to click inline links, images or CTAs.

In my case, the email lead sequence is designed to try and get people to get on a free trial, so I was interested in knowing which email in my email lead sequence was helping to drive the most traffic. I called the first email in the sequence E1, the second email E2 etc. I was also interested in seeing which link in my lead magnet PDF drove the most traffic, so I called the first link in the PDF L1, the second link L2 etc. 

Perhaps if I have a second email lead sequence it would be better if I used the name of the email lead sequence and then the email number in that lead sequence in the utm_term so I can see how each lead sequence is performing.

Similarly, if I had more than one lead magnet, I might give the name of the lead magnet in the utm_content parameter so I can determine which one is giving me the most value.

utm_term

When you advertise on Google or Bing (through Microsoft Ads) you want to know which keywords are helping drive the most traffic and also which ones are responsible for conversions.

This is what the utm_term parameter is used for. In Google Analytics it will list the keywords people used when they clicked on your pay per click ads in the Google search results page.

Google will automatically append the utm_term parameter when you create a PPC campaign in Google Ads so you don’t need to do anything else. Other platforms where you are advertising on keywords might not add the utm_term automatically or you might have to include some special text to make sure it is set up correctly.

How do I get a UTM code?

You can create a UTM tracking yourself very easily. Whenever you want to use one, just copy the following text and add it to the end of the URL you want to share:

?utm_source=SOURCE-NAME&utm_medium=MEDIUM-NAME&utm_campaign=YOUR-CAMPAIGN

Just replace SOURCE-NAME, MEDIUM-NAME, and YOUR-CAMPAIGN with your own terms

How do UTM parameters work?

The UTM tracking codes that you add on to the end of a URL to track traffic is a tracking code that is used by Google Analytics.

Other web traffic analytics tools like Matomo or Adobe Analytics have their own tracking code formats and don’t work with UTM tracking codes.

Therefore it follows that you should only be using UTM tracking codes if you’re using Google Analytics and you’ve got the Google Analytics tracking tag correctly set up on your website.

When someone visits your site after clicking a link that includes your tracking code (the link could be in an email, on Facebook, in a PDF file, in a PPC ad, etc.) the Google Analytics tracking tag picks up the UTM parameters from the URL. It then automatically groups all visitor data in Google Analytics based on those parameters.


Where does Google Analytics show you UTM visitor data?

Google Analytics doesn’t make it immediately obvious where your UTM tracking data can be found because none of the menu options mention ‘UTM’. So how do you find your tracking code data in Google Analytics?

There are two pages where you can access all your visitor data tracked through UTM codes.

If you want to see how your campaigns are performing based on the utm_campaign parameter, login to your Google Analytics account and navigate to:

  • Acquisition >> Campaigns >> All Campaigns

This page has curated all visitors that came through a UTM link by the utm_campaign label.

If you click on one of the campaigns you can drill down further to see data from all the utm_source and utm_medium parameters that you have defined for the campaign.

The second place you can see your UTM data in Google Analytics is here:

  • Acquisition >> All Traffic >> Source/Medium

This page lists all the tracked traffic that has come from a particular utm_source and all the utm_medium parameters used for that source.

If you want to see the utm_content for each traffic source then you need to select it as a secondary dimension from the drop-down menu. Confusingly, Google Analytics calls the utm_content parameter as Ad Content.

Once selected, you’ll see a second column open up and all your utm_content parameters are listed.

If you want to access your utm_term data for your pay per click campaigns, then you need to go to:

  • Acquisition >> Google Ads >> Keywords

How to format your UTM tracking codes

So that’s the theory. Let’s now take a look at how you might incorporate UTM codes in a real world scenario.

Let’s assume you work as the product marketer for BuzzApp, a tool to help marketers create a buzz because that’s what marketers get asked for a lot – “we need to create a buzz about this new feature or this thing that the company is doing”.

BuzzApp has a regular release schedule for new product features with several big features announced each year.

The latest features are being released in July 2020 and you’ve determined that your communication plan consists of announcing the features through the following channels:

  • Blog post
  • New dedicated web page that talks about the new feature
  • A notification banner running along the top of your website announcing the new feature
  • Email to customers sent via Hubspot
  • Email to prospects sent via Hubspot
  • Email to your nurturing database sent via Hubspot
  • Email to investors and advisors sent via Yesware
  • Email to the press sent via Yesware
  • New PDF collateral that the sales team can distribute to their contacts
  • New message on live chat letting people know about the new feature
  • Remarketing campaign on Facebook
  • Remarketing campaign on Google Ads
  • Posts on all social media channels: Facebook, Twitter, LinkedIn
  • Press release

Now you shouldn’t be using UTM codes to track internal links on your website – that’s what Google Tag Manager is for. Therefore you don’t need to use links with UTM tags in the blog post, dedicated web page or the notification banner on the top of your website.

For all the other channels, you would use a UTM code.

Since this is a product feature announcement and one of many that happen throughout the year, a good utm_campaign tag might be: New_Feature_Jul_2020.

You can use spaces in UTM codes but it’s generally best practice to use a hyphen or underscore instead of a space.

Formatting UTM codes for email campaigns

Your company uses Hubspot to send out emails so logically we might say that the utm_source is hubspot.

However, we’re planning to send emails to three different lists in Hubspot and the UTM code added to the blog announcement link will be the same for all three emails:

https://buzzapp.io/blog/new-features-july-2020?utm_source=hubspot&utm_medium=email&utm_campaign=New_Feature_Jul_2020

So how can we see how each list performed in Google Analytics if we’re using the same UTM code for all three lists?

Sure, you can get a detailed performance of each list from Hubspot, but we want the data for traffic and conversions in Google Analytics to see the effectiveness of each list.

There are three ways to handle this. Neither is more ‘right’ than any other in my opinion.

We could change the utm_source from hubspot to customers, prospects and nurture depending on the list. So a link in the prospects email might look like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=prospects&utm_medium=email&utm_campaign=New_Feature_Jul_2020

Unfortunately this means we lose Hubspot as a tracked source, but it might not matter if you are consistent with your naming conventions and everyone on the team knows that utm_source=prospects comes from an email sent via Hubspot.

Another way might be to keep hubspot as the source, but add the list name as well. So for the nurture list, the URL might become:

https://buzzapp.io/blog/new-features-july-2020?utm_source=hubspot_nurture&utm_medium=email&utm_campaign=New_Feature_Jul_2020

This would help you club all the different channels together (the mediums), so you can get a quick sense of which one is performing best. On the downside, you lose the ability to quickly see which source is performing the best overall.

The third way might be to define the list under the utm_medium parameter. It might look something like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=hubspot&utm_medium=email_nurture&utm_campaign=New_Feature_Jul_2020

The good thing about this approach is that you can see which source is performing the best overall and then drill down to see how sub-sets of that source are performing.

However, if you’re sending out emails from a number of different sources (ie. Hubspot for your saved lists and Yesware for your prospects) then you end up with multiple reporting lines for what is essentially all email and it becomes difficult to see how ‘email’ as a channel performed versus social or PPC.

The final option might be to use the utm_content parameter to help determine which list the traffic has come from.

https://buzzapp.io/blog/new-features-july-2020?utm_source=hubspot&utm_medium=email&utm_campaign=New_Feature_Jul_2020&utm_content=customers

The downside here is that in order to determine which list sent the traffic and conversions, you need to use the Ad Content as a secondary dimension in your Google Analytics report as shown in the screenshot below.

This makes it more cumbersome to report on compared to the other methods mentioned above. However, it does help you know which sources and mediums are performing at a higher level and gives you the option to drill down to what specifically from that source or medium was working.

A word of warning about naming your UTM parameters

At this point it’s a good idea to hit pause and talk about exactly what text you might use for utm_source and utm_campaign because there’s a chance your choices might backfire.

When someone clicks your link with a UTM tracking code, your naming choices are completely visible to the user in their address bar.

Imagine if you had a product with a freemium plan. You send out an email to your users on the free plan offering them a coupon to upgrade to a paid plan. The email is well written with UTM tracking codes used on all the links.

Everything seems fine until one of your subscribers notices this URL in their browser address bar:

https://buzzapp.io/upgrade?utm_source=freeloaders&utm_medium=email&utm_campaign=summer_upgrade

😱 Ouch!

Did you really just send an email where you called your freemium users freeloaders?

This might be a bit of an extreme example, but what about calling your email lists prospects and nurture in the utm_source? There’s no need to highlight what kind of contact you consider your users to be so either use abbreviations or more neutral words when defining the utm_source, utm_campaign and utm_content.

Formatting UTM codes for social media campaigns

Now let’s consider how we might define the UTM parameters for social media.

On Facebook we’re planning to 

  1. Publish a post on our company page
  2. Retarget everyone who saw our product page in the last 180 days
  3. Run an ad to our existing customers using a custom audience

That’s three different audiences and if we boost the post on the company page, three audiences we’re paying to reach.

At the most basic level, our tracking code could look like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social&utm_campaign=New_Feature_Jul_2020

But as you probably noticed, this doesn’t help us identify which audience might have clicked through to our site.

Just like with the email marketing tracking codes mentioned above, we could modify the utm_source or utm_medium to be a bit more specific about which audience it is based on our preference of curating all traffic by source or by medium.

If we prefer to curate all traffic by utm_medium, we could modify the utm_source to be like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook_post&utm_medium=social&utm_campaign=New_Feature_Jul_2020

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook_remarketing&utm_medium=social&utm_campaign=New_Feature_Jul_2020

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook_customers&utm_medium=social&utm_campaign=New_Feature_Jul_2020

Sidenote: I’m just using facebook_remarketing and facebook_customers as examples, based on the note above about being smart about how you label your UTM parameters, you might want to choose different labels.

If you prefer to group all campaign traffic by utm_source, you could label the utm_medium like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social_organic&utm_campaign=New_Feature_Jul_2020

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social_remarketing&utm_campaign=New_Feature_Jul_2020

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social_ads&utm_campaign=New_Feature_Jul_2020

Alternatively, we might want to make use of the utm_content parameter, in which case the URLs with UTM codes could be formatted like this:

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social&utm_campaign=New_Feature_Jul_2020&utm_content=post

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social&utm_campaign=New_Feature_Jul_2020&utm_content=remarketing

https://buzzapp.io/blog/new-features-july-2020?utm_source=facebook&utm_medium=social&utm_campaign=New_Feature_Jul_2020&utm_content=ads

Now what about if we publish a regular tweet on our company’s Twitter feed that includes a link back to our website. We’re not promoting the tweet, but we should still be tracking it to see whether Twitter is a good source of traffic and if so, what kind of traffic is converting for us.

There’s no right answer here, it’s whatever you think is the best way to describe the medium of delivery. I would personally opt to label the utm_medium as simply social but equally you might label it as tweet.

I would label it as social because that captures any post you make on any social network like Facebook, LinkedIn or Reddit, etc. While technically you could say the medium is a tweet and not an ad, it’s perhaps a little bit too specific.

We would continue building our UTM links for each channel in the new feature announcement campaign.

Once the campaign is launched we can use the data in Google Analytics to see which channel and which medium performed the best – and by ‘best’ I mean in terms of the objective of the campaign. Did we want to get as much traffic as possible? Did we want to increase the number of people that logged into our tool or maybe we wanted to see if it helped generate any more sign ups.

Finally, we can export the campaign data from Google Analytics and layer over our spend data in a spreadsheet to determine which channel gave us the best return in terms of our objective.

UTM Tools

There are a number of tools available to help you quickly create your UTM codes. The one I use most often is the UTM builder by Google:

The next steps for your UTM tracking codes

Before you start using UTM codes your first job needs to be to write down all the possible sources and mediums that your traffic can come from. 

The second step is to decide whether you are going to be more granular about the source of the traffic or the medium of the traffic.

For example, do you want to curate all traffic from Facebook under ‘facebook’ as the source and then use the utm_medium to categorize what kind of traffic it is – social_organic or social_paid.

Or are you going to curate all traffic by medium and categorize by source. For example, all the traffic from Facebook is given social as the utm_medium and in the source you define that traffic by facebook_organic and facebook_paid.

Or maybe you will decide all traffic from Facebook is given the source as facebook, the medium as social and you will use the utm_term parameter to define whether it was organic or paid traffic.

There’s no right or wrong way or best practice here, but you need to define it for your company and make sure it’s communicated to everyone in the team that builds links back to your site.

The third step is to record all the UTM tracking codes that you have created in a spreadsheet or UTM code tool so that everyone has easy access to the tracking codes.

Has this been helpful for you?

I’d love to hear your thoughts on UTM codes.

  • Do you think you should get granular about the type of traffic in the utm_source or the utm_medium? Or should you use the utm_content to distinguish between two types of traffic from the same source and medium?
  • Are UTM codes worth the extra hassle or do you think Google Analytics does a good enough job of categorizing and segmenting all your traffic sources?
  • How do you decide whether a traffic source is a utm_source or a utm_medium?