UTM Parameters Explained: How to Build Trackable Campaign URLs
Understand with AI
Discuss with your preferred AI assistant
Five standard tags — source, medium, campaign, term, and content — describe every campaign click.
utm_source, utm_medium, and utm_campaign must be present for analytics to attribute the visit.
UTM values are fully case-sensitive, so "Email" and "email" become two separate channels.
If you run email blasts, paid ads, social posts, and partner links but can't say which of them actually drove a sale, you have a measurement problem — not a marketing one. UTM parameters solve it. They are tiny tags you bolt onto the end of a link so Google Analytics (and almost every other analytics platform) can tell you exactly where each visitor, lead, and conversion came from.
This guide explains what UTM parameters are, what each one does, how to name them so your reports stay clean, and the mistakes that quietly corrupt your attribution data.
What Are UTM Parameters?
UTM stands for Urchin Tracking Module, named after the analytics company Google acquired to build Google Analytics. A UTM-tagged URL is just a normal link with extra information added after a question mark, like this:
https://example.com/spring-sale?utm_source=newsletter&utm_medium=email&utm_campaign=spring_sale_2026
When someone clicks that link, the browser sends the parameters along with the page request. Google Analytics reads them and files the visit under the right source, medium, and campaign — instead of dumping it into the vague "direct" or "referral" bucket. The parameters never change the page the visitor sees; they only describe where the click originated.
The Five UTM Parameters Explained
There are five standard parameters. The first three are required for clean reporting; the last two are optional.
- utm_source (required) — the specific platform or publication that sent the traffic, such as google, newsletter, facebook, or partner-blog.
- utm_medium (required) — the marketing channel or category, such as cpc, email, social, referral, or display.
- utm_campaign (required) — the named initiative the link belongs to, such as spring_sale_2026 or black-friday.
- utm_term (optional) — the paid keyword you bid on, mostly used in search ads.
- utm_content (optional) — a differentiator for A/B tests or multiple links in the same email, such as header-cta versus footer-link.
Google Analytics 4 also recognizes utm_id, a unique campaign ID that ties advertising cost data back to the sessions it generated. Use it when you import cost data or run Google Ads.
How to Build a UTM URL, Step by Step
1. Start with the exact destination URL
Use the final landing page, including the correct path. Always link to the https:// version — if your URL redirects from http to https, some servers strip the query string and you lose every tag.
2. Fill in source, medium, and campaign
These three are non-negotiable. Source answers "which platform," medium answers "what kind of channel," and campaign answers "which promotion." Get these right and your reports practically build themselves.
3. Add term and content only when they earn their place
Use utm_term for paid keywords and utm_content to tell near-identical links apart. Don't stuff extra detail into them "just in case" — every value becomes a row in your reports.
4. Let the tool encode it
Spaces, ampersands, and accented characters must be percent-encoded or the link breaks. A builder handles encoding for you, so you never paste a malformed URL into an ad platform.
UTM Naming Conventions That Keep Reports Clean
UTM values are case-sensitive. To Google Analytics, Email, email, and EMAIL are three different mediums, which splinters your data across duplicate rows. A simple, enforced convention prevents this.
- Always use lowercase. It is the single highest-impact rule — it eliminates the most common form of duplicate reporting.
- Pick one word separator and stick to it. Hyphens or underscores are both fine; what matters is consistency across every link your team builds.
- Standardize your medium values. Decide once whether paid search is cpc or ppc, and document it so nobody invents a new variant.
- Keep campaign names descriptive but short. Include the season or year so historical reports stay readable, e.g. q2-webinar-2026.
Quick reference table
| Parameter | Required? | Example value |
|---|---|---|
| utm_source | Yes | newsletter |
| utm_medium | Yes | |
| utm_campaign | Yes | spring_sale_2026 |
| utm_term | No | running-shoes |
| utm_content | No | header-cta |
Common UTM Mistakes to Avoid
- Inconsistent casing — the number-one cause of split, untrustworthy reports.
- Tagging internal links — adding UTMs to links between pages on your own site overwrites the original source and breaks attribution.
- Forgetting the required three — without source, medium, and campaign, the visit falls back into a generic bucket.
- Spaces and special characters — unencoded values produce broken links that some platforms reject.
- Using vanity values — a medium of "ourbiggestsaleever" is meaningless in a channel report; keep medium to standard categories.
Expert Tips
Lowercase everything, always
Because UTM values are case-sensitive, mixed casing silently duplicates your channels. Standardize on lowercase and let the tool enforce it — it is the highest-impact rule for clean attribution.
Never tag your internal links
Adding UTMs to links between pages on your own site overwrites the visitor’s original source mid-session, so a sale gets credited to the wrong campaign. Tag external campaign links only.
Frequently Asked Questions
What is a UTM code used for?
A UTM code is a set of tags added to a link so analytics tools can attribute the resulting traffic to a specific source, channel, and campaign. It lets you measure which marketing efforts drive visits and conversions instead of guessing.
Which UTM parameters are required?
Three are required for clean reporting: utm_source, utm_medium, and utm_campaign. utm_term and utm_content are optional and used mainly for paid keywords and A/B testing. GA4 also supports an optional utm_id for cost attribution.
Are UTM parameters case-sensitive?
Yes. Google Analytics treats "Email" and "email" as separate values, which splits your data into duplicate rows. The safest practice is to lowercase every UTM value so your reports stay consolidated and accurate.
Do UTM parameters hurt SEO?
UTM parameters don't directly harm rankings, but they can create duplicate-URL versions of a page. Use them only on external campaign links — never on internal navigation — and set a self-referencing canonical tag on the destination so search engines index the clean URL.