URL tracking parameters, also known as tracking codes or tracking tags, are tools that record the origin of a click.
When someone clicks on a link in one of your ads, emails, or other marketing efforts, these little snippets of computer language, which are attached to the ends of URLs, capture all sorts of valuable info about the channel, campaign, and even keyword or call to action that lead to the click.
Some prominent types of tracking parameters include gclid, utm, and msclid, which we’ll go over later in the article. Analyzing this tracking data in conjunction with user activity and conversions is a critical part of digital marketing. Doing so allows you to calculate your return on investment, test your content, manage your PPC bidding strategies, and optimize your entire digital marketing program.
In this article, we’ll take a look at:
- What are tracking parameters?
- What is a utm?
- How do you use a utm?
- What is a gclid?
- How do gclids work?
- When should I use gclids and utm?
What is a tracking parameter (a.k.a. tracking tag a.k.a. tracking code)?
A tracking parameter (such as utm or gclid) is a snippet of code that you can add to the end of a URL (the address you type into your browser to get to a web page). It is used to record bits of information about the interaction that led to the user accessing the URL, and provides data that can be used in conjunction with conversion data to evaluate the efficacy of your marketing efforts.
When someone clicks on a hyperlink in one of your digital ads, that person’s browser will automatically enter the URL to a landing page on your website and take them there. If you’ve got tracking parameters set up to track that ad, a snippet of code will be added to the end of the URL when the user clicks on the link. Depending which type of tracking parameter you use and how it’s configured, certain information about that particular click will be recorded by the snippet.
When the user arrives on your web page, your web analytics software (like Google Analytics), will read the URL, recognize the tracking parameter, and record the information it contains. When you log in to your analytics software, it will report that information to you.
What is a utm?
The acronym “utm” stands for Urchin Tracking Module. An urchin, with a lower case “u,” is a mischievous young child, especially one who is poorly or raggedly dressed; or an invertebrate sea creature that looks like a ball covered in spikes. Urchin, with an upper case “U,” is the name of an early web analytics company that was acquired by Google in the mid-2000s and became the basis for Google Analytics. The “u” in “utm” refers to the web analytics company, not the child or echinoderm.
Aside from having an unusual name, utms are used for tracking data. They are added to the end of URLs to record information about clicks, which can be used to analyze the performance of your marketing campaigns. Multiple utms can be added to a single URL—in this case, each utm you add will track a different type of information.
Every utm has two components: the utm parameter and the tracking value.
- The utm parameter is the first part of the code snippet and looks like this: “utm_source.” There are five possible parameters: “utm_source,” “utm_medium,” “utm_campaign,” “utm_content,” and “utm_term.” (See below for explanations of each parameter.)
- The second part is the tracking value. The tracking value records the information you’re trying to track, like the name of the traffic source or the keyword that the user typed in before seeing the ad.
A typical URL looks like this:
Add a couple of utms to track various pieces of information, and the URL looks like this:
In this example, the URL links to a blog on the CallRail website. In the second version, there are three utms added to the end: one recording the source (twitter), one recording the medium by which we’re distributing it (CPC, “Cost-Per-Click,” meaning paid ad), and one recording the marketing campaign responsible for displaying the link on twitter (ReportingRundown2019).
As you can see, a string of utms always begins after a question mark (?), and when you have more than one utm, you separate them with the ampersand (&).
What parameters do utms track?
There are five types of information that can be tracked via utm parameters, that can be recorded by a utm and transferred to your web analytics platform.
The “utm_source” parameter identifies the source of the web traffic. Sources include Facebook, Google, Bing, the name of a specific website, or the name of an email mailing list, to name a few.
Ex. If you tweet out a special offer with a link to a landing page, for example, the utm code would be “utm_source=Twitter.”
The “utm_medium” parameter identifies the type of traffic. Instead of the name of the source, this refers to the broader category of the marketing effort, such as social, email , cpc (paid), social (unpaid), and the like.
Ex. If you tweet out a special offer with a link to a landing page, for example, the utm code would be “utm_medium=social.”
The “utm_campagin” parameter identifies the name of the specific campaign associated with marketing effort that contains the link.
Ex. If you’re running an email marketing campaign focusing on a Labor Day sale, your utm code for links in the email might have the utm code “utm_campaign=2019_holiday_promo.”
The “utm_content” parameter identifies what type of link was clicked that lead the traffic to your site. It may differentiate between a banner ad or a search ad, or between two ads that link to the same place but have different images or copy. Or, if there are two otherwise identical links in the same ad or email, it may differentiate between those two links based on location, such as “utm_content=headerlink” vs. “utm_content=sidebarlink.”
Ex. If you’re sending an email with two different CTA links, one at the top and one at the bottom of the email, and the user clicks the CTA at the bottom, the utm code for that link would be “utm_content=bottomlink.”
The “utm_term” parameter identifies the keyword or search term that led to the link being displayed. This parameter only works for PPC advertising.
Ex. If you’re running a PPC campaign for the keyword “call tracking,” the utm code might be “utm_term=call-tracking.” Most often, you won’t be manually inserting these parameters, but letting them populate dynamically.
How do you use utm codes?
To set up and use utm parameters, there are several steps.
- Choose a URL you want to use in your ad, email, tweet, or other marketing effort.
- Build the tracking link by adding the utm parameters you’d like to track to the end of that URL. (We’ll go over formatting utm code below).
- Insert the URL with the utm code in the ad, email, tweet, or other marketing effort. Some platforms will have a separate slot for adding parameters during the creation of the ad, in which cases you’ll add the destination URL and utms separately.
- Access your web analytics software and navigate to the report where utm parameters are displayed. In Google Analytics, for instance, pages tracked with utms are automatically pushed into the Acquisition > Campaigns report.
You can manually type utm codes to the end of URLs when you insert them into your ads, emails, or other marketing efforts, or you can use a tool to build them for you and paste the resulting link into the ad.
Google offers one such tool; you enter the original URL and the various tracking values, and it spits out a link that you can copy and paste into your marketing content. This provides a time efficient way to build URLs and minimizes the chance of human error.
Here’s an example: Imagine you run a store that sells peanut butter sandwiches. You want to run an email marketing campaign that messages the people on your contacts list every Saturday morning, to remind people that sandwiches with creamy peanut butter are 25% off on Sundays. This email is part of a broader marketing campaign with multiple efforts focused on getting rid of your creamy peanut butter inventory, including other emails, search ads, and displays ads.
When you’re setting up the Saturday email, you include two Calls-to-Action (CTAs) at the top and bottom of the email that encourage people to click. Both link back landing page with a list of the benefits of creamy peanut butter and a special 2-for-1 offer. You’ve got web analytics software set up to monitor your website, and you’d like to record information about your email marketing clicks to see how they fit in with the broader campaign. To do so, you create the following URL:
This way, you’ve tracked the source (the Saturday morning email), the medium (email), the overarching marketing campaign (Dare to Cream 2019), and the location of the link that was clicked (the CTA at the top).
Your last step is to access your web analytics software (such as Google Analytics, HubSpot, and many more) and view the report that includes utm terms. The location of this report will vary across analytics tools.
You are now tracking the email you sent, but we’re not done! You also decide you want to share the link on Twitter, because why not? More eyeballs = more creamy peanut butter exchanged for cold, hard cash.
So you log on to Twitter to tweet the link to your special 2-for-1 landing page. You type, “Get the cream of the crop: 2-for-1 on creamy peanut butter sandwiches if you follow this link!
Starting with the destination link (https://www.peanutbuttersandwichshop.com/twofor/) you add the following utms:
Now just sit back and watch the sandwiches fly off the shelf.
How should you name your tracking values?
Several best practices exist to help you build utm tracking values.
Define your parameters. Make sure you’ve defined the difference between sources and mediums, for example, and that you used them in the same way every time. “Facebook” is a source, “social” is a medium, and “facebook-group-profile-tagline” is a content.
Be consistent with capitalization and punctuation. Creating a standard format and sticking with it makes accurate reporting much easier, and allows you and your team to build tracking URLs the exact same way every time. We recommend lowercase, because it’s easy to do for every word every time versus trying to remember capitalization rules. You can only have letters, numbers, hyphens, plus signs, and periods in a tracking values. Avoid using spaces because they can be changed to a %20 encoded character. Hyphens and underscores are a great way to separate words.
Keep track of your utms. Build a shareable spreadsheet to remember what utms you have floating around out there and what URLs they are associated with. When you’re running multiple campaigns with dozens of tracking parameters, it can be easy to confuse which utms go with which ads.
What is a gclid?
The acronym “gclid” stands for Google Click Identifier. The gclid is essentially the automated, information-rich younger brother of the utm. As the name suggests, gclids were introduced in the 2010s by Google, and became the default tracking parameter for clicks related to Google Ads.
Gclids are applied by a process called auto-tagging. This means they are automatically applied to the end of every URL whenever someone clicks on a link in a Google Ad.
Gclids don’t follow the standard utm parameter + tracking value format of utm codes; while they contain a ton of information, gclid tracking values are encrypted, and appear at the end of URLs as a collection for random letters.
A typical URL looks like this:
A URL with a gclid looks like this:
By encrypting gclids, Google ensures that Google Analytics is the only program that can decipher the information, thereby encouraging people to use Google tools and only Google tools.
What parameters do gclids track?
Tracking values captured by gclids include:
- Query match type: how your keyword was actually matched to the search query.
- Ad group: the ad group associated with the keyword/creative and click.
- Final URL: Google Ads Final URL
- Ad Format: text, display, or video
- Ad Distribution Network: Google Search vs Google Display
- Placement domain: the domain on the content network where your ads were displayed.
- Google Ads customer ID: the unique three-part number that’s assigned to your Google Ads account.
- Hour of day the URL was clicked.
- Placements: where your ads on the content network were placed.
- Keyword Positions: what position your ad appeared in on Google Search.
- Display targeting
- Video campaigns
- Shopping campaigns
How do you set up gclid tracking?
Unlike utms, gclids are added automatically to the ends of URLs in Google Ads, there’s no manual setup.
All you have to do is follow these steps:
- Sign in to your Google Ads account.
- Click Settings in the menu on the left side.
- Click Account settings.
- Click the Auto-tagging section.
- Click the check box next to where it says “Tag the URL that people click through from my ad.”
- Click Save.
Since gclid auto-tagging automatically reports to Google Analytics, there’s no reporting to set up in third party software like utms.
Utm vs gclid: when should you use one versus the other?
Gclids seem like a no brainer: thanks to auto-tagging, Google Ads places gclids at the ends of URLs automatically, saving time and energy spent on a tedious task like typing URL tags. Auto-tagging also keeps human error out of the equation, preventing a typo from costing you valuable data about you clicks. Utms only collect five types of information, while gclids offers nearly three times that many. And gclids require little to no additional set up in third party reporting software.
So why would you ever use a utm?
Despite the time-saving and data-recording improvements, gclids are not without limitations. For one thing, you’re trapped inside Google’s software universe. Thanks to the encrypted gobble-dee-gook at the end of gclid-tagged URLs, third party software can’t decipher the information stored therein. This means that any in-house tools, CRMs, or other third-party analytics software is rendered useless in the face of a gclid.
Furthermore, gclids only work for marketing efforts originating in Google Ads. While the Google Advertising Network is large, there are still many outlets that exist beyond it, from bing ads to email marketing and more.
Examples of when to use gclids, utms, or both.
There are two scenarios in which you should only use utms: If you’re using neither Google Ads nor Google Analytics OR if you’re using Google Ads but NOT Google Analytics. In these cases there’s no point in using gclid: no other software aside from Google Analytics can decipher the encrypted tracking values, so utms are the only viable solution.
If you’re ONLY using Google Ads and Google Analytics, with no CRMs, in-house systems, or third-party analytics, then only use gclids. In this case, don’t waste time manually creating utms: gclids will capture the same information as utms (and more), and plus, they populate automatically saving you time.
Both utm and gclid
There are two scenarios in which it makes sense to use the belt and suspenders approach and apply a mixture of utms and gclids. The first is if you’re using Google Ads, Google Analytics, AND some other software that reports on ad clicks. This might include CRMs, in-house systems, or third-party analytics software like HubSpot. The second is if you’re using Google Ads AND another type of advertising or marketing effort, such as Microsoft Advertising or email marketing.
In some cases, websites don’t allow arbitrary URL parameters such as gclid. In these instances, Google recommends using manual utm tags.
There are advanced ways to manage your Google Ads tracking in Google Analytics. To learn more about this approach, peruse Google’s documentation on tracking templates.
For the most advanced trackers, Google’s ValueTrack parameters allow for complex tracking rules, include “if” statements.