◔ Analytics & measurement

UTM parameters: tracking campaigns without creating confusion

What the five UTM parameters are, how to fill them in with consistent rules, which mistakes pollute your reports and why they never belong on internal links.

When someone arrives on a site from a newsletter, a social post or a QR code printed on a flyer, the analytics tool often has no idea where they came from. The referrer may be missing, generic or point to an app. UTM parameters solve the problem simply: you add a few labels describing the source to the URL, and the tool reads them.

The five parameters

A link with UTMs looks like this:

/backup-guide/?utm_source=newsletter&utm_medium=email&utm_campaign=october_backup

There are five standard parameters:

Parameter Question Examples
utm_source Who sent the traffic? newsletter, linkedin, trade_fair_flyer
utm_medium Through which medium? email, social, cpc, qr, affiliate
utm_campaign For which initiative? october_backup, course_launch
utm_content Which variant or position? top_button, signature_link
utm_term Which keyword? used mainly in paid ads

The first three are the truly essential ones. utm_content helps when the same message contains several links to the same page and you want to know which works best.

Why the medium matters so much

Many tools group traffic into channels, such as email, social or paid search, based on the value of utm_medium. If you write utm_medium=newsletter instead of email, the tool may not recognise it and classify those visits as "other". Before choosing values, check which terms your tool associates with each channel and always use those.

Writing rules

UTM parameters are free text, and free text is the enemy of reports. A tiny difference creates a separate row:

  • Newsletter, newsletter and news-letter are three distinct sources for most tools;
  • a trailing space creates a different value;
  • an accent or special character may be encoded in different ways.

That is why it pays to set a few rules and always follow them:

  1. everything in lower case;
  2. underscores to separate words;
  3. no spaces, accents or special characters;
  4. a closed list of values for utm_medium and another for utm_source;
  5. campaign names in a fixed format, for example topic and period.

The simplest way to follow the rules is never to write links by hand. A shared spreadsheet with columns for destination URL, source, medium, campaign and content, plus a formula that builds the final link, removes most errors. The register is useful afterwards too: six months from now you will know exactly which links were used and where.

In my work I have often seen campaign reports ruined by a single colleague writing values their own way. A shared register solves the problem without constant checking.

UTM parameters should be used only on links coming from outside. If you put a UTM on an internal banner, for example from the home page to an offer page, many tools start a new session or overwrite the original source. A visitor who came from organic search becomes, as far as the tool is concerned, an "internal banner" visitor, and organic search loses credit for the conversion.

To measure clicks on internal links, use an event instead, with a property indicating where the link sits.

Other precautions

  • Canonical links: pages reached with UTMs should carry a canonical tag pointing to the URL without parameters, so search engines do not index duplicates.
  • Short URLs and QR codes: the UTM goes in the final destination URL, not in the shortened one. Always test a QR code before printing it.
  • Personal data: never put email addresses or customer identifiers into parameters. They would end up in analytics reports and in the logs of various systems.
  • Cleaning the URL: some sites remove the parameters from the address bar once the script has read them, so anyone copying and sharing the link does not carry the original source along.

Reading the results

Once the data is in, the most useful comparison is not visits per campaign but what those visits produce: enquiries, sign-ups, purchases. A campaign that brings few but highly interested visitors is worth more than one that creates a traffic spike with no consequences.

In short

  • UTM parameters label external links with source, medium and campaign.
  • Use utm_medium values your tool recognises, or the traffic ends up in the wrong channels.
  • Write everything in lower case, without spaces or accents, using a shared link register.
  • Never use UTMs on internal links: they overwrite the real source.
  • Judge campaigns by the conversions they produce, not just by visits.
MM
Marco Marzaduri

Marco Marzaduri works in cybersecurity, digital forensics and web development. A computer science graduate, he combines rigorous technical analysis with attention to the people who use technology.

Read also