NOW AVAILABLE: Unlock Data-Driven Insights with Benchmarks, Anomaly Detection & Forecasting

UTM Tracking: What Are UTM Parameters and How To Use Them?

What Are UTM Tracking Codes - An Overview of UTM Parameters and How to Use Them

QUICK SUMMARY:

UTM tracking involves using specific tags in URLs to monitor traffic sources accurately. These UTM parameters provide insights into the origin and volume of web traffic, such as which social media platforms generate the most visits, by utilizing analytics tools for campaign tracking. The technique of using UTM tracking parameters is important for evaluating the specific link performance when measuring website traffic and digital marketing campaigns.

As a marketer, you know your marketing is driving traffic to your client’s websites, but do you have the hard data to prove it? On a client call, can you show which exact tweets or guest posts generated leads and which ones failed?

An old Peter Drucker quote – “what gets measured gets managed” – is more applicable than ever to modern agencies. Unless you can measure the impact of your marketing, you can neither improve it nor use it as proof of your work.

This is where UTM tracking comes into play.

These special UTM codes can be added to the end of any website URL to track clicks and the performance of marketing activities.

In this post, I will help you understand UTM parameters and show you how to use these codes to track your marketing performance.

You’ll also get access to Google Analytics customizable report templates that will streamline your client reporting–these will save you loads of time by automatically tracking your clients’ web analytics under one roof and showing your impact in easy-to-understand reports!

What Are UTM Tracking Codes?

UTM parameters are simple snippet codes that you add to the end of a URL to track the performance of campaigns and content. You can track 5 standard variants of UTM parameters: source, campaign medium, campaign, term, and content. Dimensions you track via UTM codes show up in your Google analytics reports to give you a clearer insight into marketing performance. It is important to set up your Google Analytics account properly to ensure accurate tracking.

UTM Tracking Parameters Explained

UTM stands for Urchin Tracking Module, although some in the digital marketing industry still refer to it as the Urchin Traffic Monitor. Whichever one you use, this name comes from Urchin Tracker, a web analytics software that served as the base for Google Analytics.

A UTM code looks something like this:

http://yourwebsite.com/your-post-title/?utm_source=google

The part starting after '?' is the UTM code. As you might have guessed, this particular code tracks who sent the traffic to the page (i.e. the source).

The UTM tagging code itself has two components:

  • UTM Parameters - that starts with utm. There are 5 standard parameters you can track: utm_source, utm_medium, utm_campaign, utm_content, and utm_term (more on these below).

  • Tracking variable – a unique variable to identify the dimension being tracked (such as the name of the traffic source). The "=" sign precedes this variable. You can have only numbers, letters, hyphens, '+' sign and periods in the variable.

Although the most common UTM parameters used for tracking data are source, medium, and campaign; UTM parameters can be long and complex. Take, for instance, this Inbound.org UTM link (from a Facebook post-click):

UTM parameters URL code example

This UTM code example tracks multiple variables, such as traffic source, traffic campaign, etc.

Adding the UTM tracker doesn’t impact the actual page. You can delete the UTM code from the URL, and the page will load normally.

Download a UTM Parameters Tracking Code Cheat Sheet
Let's make your life a little easier with our UTM planning sheet and reference guide!

Why Are UTM Codes So Important?

The code only serves one purpose: to help your analytics tool track the source of your visitor.

For agency marketers, this means you can use these UTM parameters to calculate the impact of your campaigns. If you've ever struggled with marketing attribution, UTM codes will come in extremely handy.

What Can You Track With UTM Parameters?

There are five different UTM parameters. The first 3 are by far the most used parameters (Source, Medium, Campaign), but for additional insights, you may also choose to track all 5. Here's exactly what you can track with each:

1. Traffic Source

Use traffic source UTM parameters to track where the traffic originated from. The parameter added to your URL is utm_source. Traffic sources could be Facebook, Google, Bing, inbound.org, or the name of an email list. Remember, this should be the main traffic source and not a specific social media post (we'll get to that later).

UTM Parameters Example: &utm_source=twitter

2. Medium

The medium UTM parameter tracks what type of traffic the visitor originated from – CPC, email, social, referral, display, etc.

These UTM tags help differentiate between paid social media ads and organic social media traffic based on viral Instagram posts, for example. The parameter is utm_medium.

UTM Parameters Example: &utm_medium=cpc

3. Campaign Name

The campaign parameters allow you to track the performance of a specific campaign. For example, you can use the campaign parameter to differentiate traffic between different Facebook Ad campaigns, Google ads campaign ID, or email campaigns. (See more on naming conventions below.) The parameter is utm_campaign.

UTM Parameters Example: &utm_campaign=example-campaign

4. Content

In case you have multiple links pointing to the same URL (such as an email with two CTA buttons or various social media links), use UTM parameters to track which link was clicked. The UTM parameter is utm_content.

UTM Parameters Example: &utm_content=navlink

You can also use these UTM tags to track the effectiveness of your agency's YouTube SEO processes by including the name or ID of the YouTube video that drove the click. The same applies to track influencer marketing results, whatever details needed to track the source, campaign, or medium can be added to a UTM tracking parameter.

5. Keyword Term

The keyword UTM parameter allows you to track which keyword term a website visitor came from. This parameter is specifically used for paid search ads. The parameter is utm_term.

UTM Parameters Example: &utm_term=growth+hacking+tactics

See How Fast & Easy Client Reporting Can Be
Build a demo report in seconds using metrics from some of the 80+ built-in data integrations. Reporting has never been easier.
Generate Your Report Demo Now

How To Use the UTM Parameters in Google Analytics

You can use these codes in any combination by separating each of the UTM parameters with the '&' sign.

Thus, you might have a simple URL that simply wants to track visitors’ actions from an email campaign.

yoursite.com/your-page/?utm_campaign=spring-sale

By adding the utm_campaign parameter, you can track the performance of your "Spring Sale" email campaign in Google Analytics. If you run a Spring Sale every year, add the year to the parameter (e.g. utm_campaign=spring-sale-2022) to differentiate each year's campaign within the UTM tags. Do you want to know how many sales were generated from an email campaign? UTM links are your answer.

You may also choose to have a more complex code that tracks multiple UTM parameters. Here is an example of tracking the source, medium, campaign name, medium, and content:

yoursite.com/your-page/?utm_source=facebook&utm_medium=cpc&utm_campaign=springsale&utm_content=shoead

How to View UTM Code Performance in Google Analytics

Once you add the UTM code to your campaign's URL, you can track the performance in Google Analytics in a few different reports.

  • Create a custom report under "Customization" > "Custom Reports". Add Medium, Campaign, or Source as a dimension and the metrics you want to view.

  • Go to Acquisition → Overview → All Traffic → Source/Medium to view traffic.

  • Go to Acquisition → Campaigns → All Campaigns to view traffic based on your custom campaign names.

UTM tracking source and campaign showing tracking results of UTM parameters in Google Analytics

How to View UTM Code Performance in GA-4

To track the performance of UTM codes in GA-4, navigate to the 'Acquisition' report, then select 'Traffic acquisition'. This reportF showcases user engagement metrics by source, medium, and campaign—the core UTM parameters. To view each, simply select the details you are after in the drop-down to pick by source, medium, or campaign.

GA-4 Session Source Medium Campaign Report

It's important to note that GA4's shift towards event-based modeling offers a more granular view of user interactions, making it essential to adjust filter settings accordingly. This approach allows for a deeper analysis of campaign effectiveness, highlighting the evolution from the session-based focus of Universal Analytics to the user-centric insights of GA4.

For those still struggling with the shift to Google Analytics 4, the following table outlines the fundamental differences in how UTM parameters are used and analyzed in Universal Analytics and GA4, emphasizing the shift from session-based tracking to a more flexible event-based model in GA4.

Aspect

Universal Analytics

Google Analytics 4

Data Model

Session-based, tracking individual sessions as the core measurement unit.

Event-based, focusing on user interactions (events) rather than sessions.

UTM Parameter Tracking

UTM parameters primarily impact session-level data, attributing sessions to specific campaigns.

UTM parameters impact event data, allowing more granular tracking of user interactions tied to campaigns.

Session Definition

Sessions are created based on time-based expiration (30 minutes of inactivity) and new sessions start with new UTM parameters.

GA4 does not rely on session restarts based on UTM parameters; instead, it treats them as event-level dimensions.

Attribution Models

Offers several predefined models, including Last-Click, First-Click, and others, with a focus on session-based attribution.

Attribution is more flexible with user-defined event-level tracking, allowing more complex attribution paths.

Custom Dimensions & Metrics

Limited to specific dimensions and metrics defined at the session, user, or hit level.

Custom dimensions and metrics are more flexible, with a broader scope of events, including UTM parameters as part of event data.

Reporting Interface

Standardized reports with heavy reliance on session data, making UTM-based reports straightforward but less flexible.

Customizable reports with deeper integration of UTM parameters into event data, allowing for more detailed and tailored insights.

Conversion Tracking

Conversions are typically tracked at the session level, tied to UTM parameters for attribution.

Conversions are tracked as events, enabling more precise mapping of UTM parameters to specific user actions.

Cross-Device Tracking

Less robust, with limitations in accurately tracking users across devices within the same session or campaign.

Enhanced cross-device tracking through the event-based model, providing a more comprehensive view of UTM parameter influence across devices.

How To Create UTM Codes in Google Analytics?

There are multiple ways to create UTM parameters. Below, I'll cover the most popular ones:

1. Manual Method

There is nothing technically complicated about UTM codes. Your first option is to add the parameters manually.

This is as simple as typing in individual UTM parameters at the end of your URL. The tricky part here is not making any errors! UTM codes can get pretty lengthy, and you're bound to make mistakes, so I generally don't recommend the manual method.

However, if you simply want to add the name of a campaign or source to the end of a URL, typing it out is a simple option.

For example, suppose I'm submitting a guest post and want to track the number of clicks my author bio link receives.

Thus, I might add UTMs tags to a URL like this in my bio:

http://mysite.com/page/?utm_source=blogsite.com&utm_content=author_bio

2. Google URL Builder

The Google Analytics Campaign URL Builder is an easy way to quickly add UTM parameters to your campaigns instead of manually creating them yourself, making it a godsend for those with limited coding experience or knowledge.

To use the URL Builder, simply fill out the form by entering the URL and required fields, and it will create a custom tracking URL for your campaigns! If the URL is too long, you can easily shorten it as well using Bitly.

A screenshot of the campaign URL builder from Google Analytics

To use it, simply enter your website address. You are required to enter the campaign source (so that you can keep track in All Traffic → Source/Medium); the rest of the UTM parameters are optional.

UTM code website URL and campaign information to populate UTM paramaters

After entering your desired parameters, scroll down to see your URL.

Google Analytics generated URL including UTM parameters in the link code

Copy and paste this link with the UTM code into your campaign or content.

Yes! You Can Create Client Reports in 11 Seconds!
No more juggling platforms and metrics, automatically create client reports in less time than it takes to grab a coffee.
Discover 11-Second Smart Reports

What’s New? Comparing UTM Parameters in Universal Analytics vs. Google Analytics 4

The new model for UTM tracking in GA4 (compared to Universal Analytics) simplifies tracking by reducing the reliance on manual UTM tagging and introducing automatic event tracking. It also adds some new parameters. Let’s see how the changes Google Analytics 4 compares to Universal Analytics.

UTM Codes in Universal Analytics

The classic codes that everyone is used to from Universal Analytics are still in play today, including:

  • Source–Where the traffic came from, such as a social media platform or search engine

  • Medium–What brought the traffic? (i.e., email, CPC, or referral)

  • Campaign–Which campaign is this traffic associated with?

  • Term–What are the exact keywords that triggered the ad?

  • Content–Which are the different versions of the same ad or link? (i.e., different button colors, ad sizes, or location on the page)

In addition to those five standard UTM parameters, there is also the Campaign ID (utm_id) which allows you to assign campaigns with a unique ID that complements the other parameters for even more in-depth campaign tracking and reporting

New UTM Parameters in GA4

UTM parameters in GA4 have been updated to align with Google's current recommendations and include additional parameters for campaign tracking, as well as tracking user behavior such as:

  • Dynamic parameters

  • Event parameters

  • User properties

But GA4 also goes beyond the UTM parameters supported by Universal Analytics mentioned in the previous section (i.e., Source, Medium, Campaign, Term, Content, and ID) with the following additional parameters:

  • Source Platform

  • Creative Format

  • Marketing Tactic

Ways To Use UTM Parameters

You now know what UTM parameters are, what you can track and how to create them, the most important question still remains: how should you actually use UTM codes to track your marketing campaigns?

There are essentially three ways you'll want to use these codes:

1. Know Where Your Traffic Is Coming From

The top reason to use UTM parameters is to know exactly where your website traffic comes from. You can accomplish this using the campaign, source, and medium parameters.

Google Analytics displays default channel groupings in their interface, making it easy to track UTM links.

However, using UTM codes, you can track sources more precisely. UTM parameters are especially helpful in understanding your referral and direct traffic in Google Analytics.

In Google Analytics, you can navigate to Acquisition -→ All Traffic -→ Referrals to see which sites generated traffic.

Google Referral Traffic Report Example

In this sample account, we see referral traffic from Quora.com.

However, what if you wrote 10 posts on Quora and wanted to know which post generated traffic?

By adding &utm_campaign=name-of-post UTM parameters to the end of your link on Quora, you can see in Google Analytics which posts generated traffic.

Direct Traffic is often another mysterious traffic source in Google Analytics. It primarily includes visitors that type your URL directly into their browser or bookmark your page.

But, direct traffic also includes visitors that click links in emails, ebooks, and other offline marketing materials.

Add UTM links that specify the source of traffic that would otherwise be categorized as "direct."

For example, if you write an ebook that includes links to your website, add UTM parameters to those links like the following:

mywebsite.com?utm_source=ebooks&utm_campaign=agency_playbook

In Google Analytics, you can filter your traffic by source to understand how your ebook performed in generating traffic and new leads.

google analytics referral traffic dashboard for UTM tracking

Use the Google Analytics dashboard template in AgencyAnalytics to see your referral traffic in an intuitive way.

Suppose you run a newsletter for your client. Every week, you send out half a dozen links to interesting stories from around the web. In between, you also include a couple of CTAs to your client's site.

You probably already know the newsletter open and click rates. But do you know which links in your newsletter get the most clicks and which get ignored?

This is another situation where UTM parameters come in handy.

By adding the utm_content parameter to different links in the newsletter, you can track the number of clicks they receive:

Thus, a shopping newsletter might have two separate UTM tags for shoes and jackets, like this:

  • utm_source=mailchimp&utm_campaign=newsletter1&utm_content=shoes

  • utm_source=mailchimp&utm_campaign=newsletter1&utm_content=jackets

Now when you log into Google and go to Acquisition → Overview → Campaigns → All Campaigns, you'll be able to see which link in your "Newsletter1" campaign drove more traffic.

There are countless ways to use this UTM parameter. For instance, you might create separate utm_content codes for individual banners in a banner ad campaign. Or you might add a custom code to your email signature link to track its total clicks.

3. Group Traffic by Medium

Suppose you're running a social media marketing campaign for a client.

As part of your marketing activities, you share your content on popular social networks – Facebook, Twitter, Instagram, TikTok, etc. These show up under the "Social" channel in Google Analytics.

However, what if you promoted the content on a social media platform Google doesn't recognize as "social" in GA, such as imgur.com?

An example of a referral traffic report including Imgur referrals based on UTML tracking codes inside Google Analytics

In such a case, you'd have no way to show your social marketing results.

This is where you can use utm_medium. By adding utm_medium=social to all links you share on any social channel, you use UTM parameters to track your performance across all social networks.

You'll find that the utm_medium parameter is particularly useful for conducting a macro-level traffic pattern analysis. To measure their traffic over time, you can group all links into a few broad mediums – social, CPC, search, email, referral, etc.

The utm_medium parameter is especially helpful for differentiating paid traffic.

For example, all of your traffic from Facebook will appear as "social" by default in Google Analytics. If you are running paid campaigns in Facebook Ads, you don't want that traffic grouped with your organic social traffic!

By adding utm_medium=cpc or utm_medium=cpm to your Facebook Ads URL, you can group all paid traffic into one report.

How to enter URL parameters in Facebook Ads

4. Track Traffic for Different Campaigns

If you had a new product launch, can you tell with certainty that the traffic came from the launch campaign? How many of your holiday marketing campaigns led to successful conversions?

Tracking these metrics is one of the hardest things for marketers. Basic GA data makes it next to impossible to figure out which marketing campaigns are driving your current results.

The utm_campaign parameter solves this problem. For instance, if you were running a new 20% off discount campaign, you could organize all your links like this:

  • utm_campaign=20off&utm_source=facebook

  • utm_campaign=20off&utm_source=googleplus&utm_content=first-link

Here's another example: suppose you wanted to track the marketing performance for different customer personas.

You could organize all personas into different campaigns, like this:

  • utm_campaign=persona1

  • utm_campaign=persona2

These are just some ways to use utm_campaign. As an agency marketer, you'll find this parameter indispensable.

Automated Client Reports. Ready in 30 Minutes or Less.
Spend Less Time Creating Reports and More Time Delivering Results
Start Your 14-Day Free Trial

Best Practices for UTM Tracking

Before you add UTM codes to your campaign links, there are a few things you should keep in mind:

1. Establish a UTM Naming Convention From the Start

It's important to establish naming conventions that your entire team will use. If half the people on your team are using "facebook.com," and the other half are using "facebook" under "utm_source," you'll just get muddy data.

Before you start a campaign, agree on naming conventions for common parameters. This should include the names for different mediums ("social" vs. "social media", "search" vs. "paid search", etc.) and traffic sources ("facebook" vs "facebook.com" or "reddit" vs "reddit.com").

Even capitalizations or spaces will make your analytics a mess by splitting the same campaigns into two if you follow different conventions. Set up rules from the beginning.

  • Will you use underscores or dashes in a campaign name?

  • Will all links use only lowercase?

Generally, it’s best practice to use all lowercase in your UTM tracking links.

2.  Use Easy-To-Understand Names

The UTM parameters for your campaign, content, and source links should be easy to understand. Anyone looking at the code should be able to figure out what the code means at one glance.

For instance, here is a UTM tracking code used by Inbound.org

https://inbound.org/article/is-linkedin-killing-slideshare?utm_medium=paid&utm_campaign=facebook-worldwide-loggedinusers30days-np-allseg&utm_source=facebook.com&utm_term=linkedin

Based on the campaign name alone, you can see that it targets worldwide Facebook users who have been logged in during the past 30 days.

Anyone can understand this UTM code even if they have no idea what's going on behind the scenes.

In contrast, consider this UTM code:

https://www.goibibo.com/offers/?utm_source=Mailers&utm_medium=_ret_harvest_130117&utm_term=ret_harvest_130117&utm_campaign=_ret_harvest_130117

Not only does this code use the same name for multiple parameters (term, medium, and campaign), the name itself is nonsensical. Without context, it is impossible to understand what this code is actually tracking. Sure, you can create a naming convention that associates a campaign with a numerical code. But you're making analysis a lot more difficult by not creating an easy-to-understand name.

The complexity of a UTM code is directly related to its length. As you start running more sophisticated campaigns, your URLs will become longer and longer.

This isn't the best thing from a UX perspective.

The solution: link shorteners. By using a tool like Bit.ly or Rebrandly, you can turn lengthy links into more shareable URLs. The shortened link will still keep the UTM parameters intact.

This is especially helpful for your social media posts.

Rebrandly link shortener homepage screenshot
Don’t forget to download our UTM parameters tracking code cheat sheet
Let's make your life a little easier with our UTM planning sheet and reference guide!

Over To You

Improve your client reporting instantly with a SEM reporting tool that automates the data-retrieval process for all your clients.

google analytics report template example

Use this exact Google Analytics report template to automatically populate your clients’ latest data. Try AgencyAnalytics free for 14 days and automate your client reporting in minutes.

And remember to use the right naming conventions and hide lengthy links using link shorteners.

Receive Agency Growth Tips, Delivered to Your Inbox

Christian Sculthorp

Written by

Christian Sculthorp
Read more posts by Christian Sculthorp ›

Get Started for Free

Try AgencyAnalytics risk-free for 14 days. No credit card required.
AgencyAnalytics Dashboard Preview