How to Use UTM in Google Analytics

Cody Schneider9 min read

If you're spending time and money on marketing, you need to know what's working and what isn't. Answering that question starts with accurately tracking your campaigns, and that's precisely where UTM parameters come in. This guide will walk you through what UTMs are, how to set them up without messy errors, and exactly where to find your campaign data in Google Analytics 4.

What Are UTM Codes?

UTM codes (or parameters) are simple text snippets you add to the end of a URL to help you track a visitor's origin. They don't change the destination page - they just give Google Analytics extra information about where the click came from. UTM stands for "Urchin Tracking Module," a nod to the company whose software became the foundation for Google Analytics.

Think of it like being a detective. Without UTM codes, a visitor arrives on your site from a link in your email newsletter, and Google Analytics might just label them as "Direct" traffic. But with UTMs, that same visitor is precisely tagged: you know they came from your email, specifically the May newsletter, and they clicked the "Shop Now" button in the hero section.

There are five standard UTM parameters, three of which are essential while two are optional but very useful for getting granular.

  • utm_source (Required): This identifies where the traffic is coming from. It tells you the specific platform or referrer. Examples: google, facebook, newsletter, bing
  • utm_medium (Required): This identifies how the traffic got to you. It's the general marketing channel. Examples: cpc (cost-per-click), email, social, organic, affiliate
  • utm_campaign (Required): This identifies the why. It names the specific campaign, slogan, or promotion. Examples: spring_sale_2024, new_product_launch, q2_promo
  • utm_term (Optional): This is typically used in paid search campaigns to track the specific keywords you're bidding on. Examples: blue_running_shoes, marketing_automation_software
  • utm_content (Optional): This is used to differentiate links that point to the same URL from within a single ad or promotion. It’s perfect for A/B testing. Examples: blue_button, header_link, footer_cta

When you combine them, a standard URL like https://yourwebsite.com/landing-page turns into something like this:

https://yourwebsite.com/landing-page?utm_source=facebook&amp,utm_medium=social&amp,utm_campaign=spring_sale_2024&amp,utm_content=video_ad

Looking at that link, you can immediately tell that the click came from Facebook (source), via a social post (medium), as part of your 2024 spring sale (campaign) and was specifically from the video ad (content). This depth of information is what separates guessing from knowing.

Why Bother with UTM Parameters?

Creating these links might seem like extra work, but the payoff is enormous. Here’s why making UTM use a habit is non-negotiable for serious marketers:

  • Pinpoint Your Best Channels: You'll finally be able to say with confidence, "Our email newsletters drive 30% of our trial signups," or "That Facebook campaign had a great click-through rate but didn't convert."
  • Measure Campaign ROI: When you connect engagement and conversions back to a specific campaign, you can calculate your return on investment accurately. No more throwing budget at channels that don't perform.
  • Solve the "Direct / (none)" Mystery: A significant portion of traffic that GA can't identify gets lumped into "Direct / (none)." This includes clicks from emails, social media apps, and text messages. UTMs fix this by explicitly telling GA where the user came from.
  • Optimize Your Creative: By using utm_content, you can test which calls-to-action, images, or ad copy performs best. "Did the video ad outperform the image ad?" "Does the button in the header get more clicks than the link in the footer?" UTMs give you the answers.

How to Build Your Own UTM Links

The key to successful UTM tracking is consistency. If one person on your team uses "facebook" as a source while another uses "FB," Google Analytics will treat them as two separate channels, splitting your data and making analysis a mess. Here are a couple of simple ways to build your URLs and maintain sanity.

Method 1: Google's Campaign URL Builder

For one-off links, Google provides a free and straightforward tool called the Campaign URL Builder. It's the perfect place to start.

  1. Navigate to the Campaign URL Builder for GA4.
  2. Enter the destination URL of your landing page in the "Website URL" field.
  3. Fill in the required fields: campaign_source, campaign_medium, and campaign_name.
  4. Fill in the optional campaign_term and campaign_content fields if you need them.
  5. As you type, the builder automatically generates the full campaign URL at the bottom of the page.
  6. Copy the generated URL and use it in your ad, social post, or email. You can even use a link shortener like bit.ly to make it cleaner.

Method 2: A Spreadsheet for Consistency

When you're running multiple campaigns or working with a team, the URL builder can be slow and error-prone. A shared spreadsheet in Excel or Google Sheets is a much more robust solution. It acts as a single source of truth for your team and helps enforce your naming conventions.

Create a simple spreadsheet with the following columns:

  • Base URL
  • Campaign Source (utm_source)
  • Campaign Medium (utm_medium)
  • Campaign Name (utm_campaign)
  • Campaign Term (utm_term)
  • Campaign Content (utm_content)
  • Generated UTM Link (Formula)

In the "Generated UTM Link" column, you can use a formula to automatically stitch everything together. This saves time and prevents copy-paste errors.

UTM Best Practices You Can't Afford to Ignore

Whether you're using a builder or a spreadsheet, follow these rules to keep your data clean and accurate:

  • Be Consistent: This is the golden rule. Decide on a naming convention and document it for your whole team. Is it facebook or FB? email or newsletter? cpc or paid_search? Pick one and stick to it religiously.
  • Use Lowercase: Google Analytics is case-sensitive. Facebook and facebook will show up as two different sources in your reports. Enforce lowercase for everything to avoid splitting your data.
  • Use Underscores or Hyphens, Not Spaces: Spaces in URLs get converted into messy escape codes (like %20). Use underscores spring_sale or hyphens spring-sale to separate words and keep your links clean.
  • Be Descriptive but Concise: Your campaign names should be easy to understand at a glance. q2_promo_2024_usa_newusers is much more helpful than campaign_123.

Where to Find Your UTM Campaign Data in GA4

You've built your URLs and launched your campaigns. Now, where do you find the results? Google Analytics 4 automatically recognizes UTM parameters and organizes the data for you. Here are the two main places to look.

The Traffic Acquisition Report

This is the most direct place to view campaign performance. It shows you data based on the source of the first session that brought a user to your site.

  1. From your GA4 dashboard, navigate to Reports > Acquisition > Traffic acquisition.
  2. By default, this report is grouped by "Session default channel grouping." To see your UTMs, click the dropdown arrow above the first column.
  3. Select "Session source / medium" to see those two parameters combined (e.g., "google / cpc," "newsletter / email").
  4. You can also choose "Session campaign" to view performance by campaign name, or just "Session source" or "Session medium" individually.
  5. To dig deeper, click the blue "+" icon next to the primary dimension to add a secondary dimension. For example, set your primary dimension to "Session campaign" and add "Session source / medium" as a secondary dimension to see which channels drove traffic for each campaign.

From here, you can analyze metrics like users, sessions, engagement rate, conversions, and revenue associated with each tagged link.

Building a Custom Report in Explore

For more control and flexibility, GA4’s "Explore" section lets you build custom reports from scratch.

  1. Navigate to the Explore tab on the left-hand menu and click "Blank new exploration".
  2. Under the "Dimensions" section in the first column, click the "+" and import the UTM-related dimensions. Search for and check the boxes for:
  3. Next, under "Metrics," import the key performance indicators you want to measure. Common metrics include Sessions, Total users, Conversions, and Total revenue.
  4. Now, drag your chosen dimensions into the "Rows" section and your metrics into the "Values" section. For example, drag "Session campaign" to Rows and "Conversions" and "Total revenue" to Values.
  5. Your custom report will instantly populate in the main window, giving you a tailored view of which campaigns are hitting your goals. This method is incredibly powerful for deep-dive analysis.

Common UTM Mistakes (and How to Fix Them)

UTMs are a superpower, but a few simple mistakes can corrupt your data. Here are the most common pitfalls to avoid:

  • Using UTMs on Internal Links: Never use UTMs for links on your own website (e.g., a link from your homepage to your pricing page). When a user clicks a UTM-tagged link, it overwrites the original source information and starts a new session in GA. This will destroy your attribution data, making it look like your own website is your top source of traffic. UTMs are for external traffic only.
  • Inconsistent Casing: We've said it before, but it's worth repeating. linkedin and LinkedIn are not the same thing to GA4. Always use lowercase.
  • Mixing Up Source and Medium: A common mistake is using cpc as a source and google as a medium. Remember the rule: Source is the "where" (google), and medium is the "how" (cpc).
  • Unnecessary UTMs for Google Ads: If you have linked your Google Ads account to Google Analytics, there is no need to add UTMs to your final URLs manually. The auto-tagging feature handles it automatically, passing even richer data than manual UTMs can provide.

Final Thoughts

Consistently using UTM parameters is a fundamental practice for moving from guesswork to a data-driven marketing strategy. By tagging your inbound URLs, you create a clear map that shows exactly how your audience finds you and which efforts are driving revenue, sign-ups, and engagement in Google Analytics.

Of course, even with perfect UTM tagging, logging into multiple platforms and manually building reports can feel like a time-consuming chore. That’s where we wanted to make things easier. We built Graphed to eliminate the friction between data and insight. Instead of clicking through GA4 menus, you can connect your data and just ask for what you need in plain English, like, "show me a dashboard comparing revenue and conversions from our spring_sale_2024 campaign, broken down by source." Our tool builds the report for you instantly, allowing you to get answers in seconds, not hours.

Related Articles

How to Connect Facebook to Google Data Studio: The Complete Guide for 2026

Connecting Facebook Ads to Google Data Studio (now called Looker Studio) has become essential for digital marketers who want to create comprehensive, visually appealing reports that go beyond the basic analytics provided by Facebook's native Ads Manager. If you're struggling with fragmented reporting across multiple platforms or spending too much time manually exporting data, this guide will show you exactly how to streamline your Facebook advertising analytics.

Appsflyer vs Mixpanel​: Complete 2026 Comparison Guide

The difference between AppsFlyer and Mixpanel isn't just about features—it's about understanding two fundamentally different approaches to data that can make or break your growth strategy. One tracks how users find you, the other reveals what they do once they arrive. Most companies need insights from both worlds, but knowing where to start can save you months of implementation headaches and thousands in wasted budget.