---
title: "UTM discipline and channel groupings | Optimize All Academy"
description: "Why UTMs matter When someone clicks a link in an email, a WhatsApp broadcast, an influencer's bio or a paid social ad, GA4 needs to know where they came…"
url: https://optimizeall.com/learn/web-analytics-with-ga4/utm-discipline
updated: 2026-10-05
---

Web Analytics with Google Analytics 4 · Campaign tracking, consent and privacy · lesson 10 of 20 · 11 min

# UTM discipline and channel groupings

## Why UTMs matter

When someone clicks a link in an email, a WhatsApp broadcast, an influencer's bio or a paid social ad, GA4 needs to know where they came from. Some sources are detected automatically (search engines, referrals, Google Ads with auto-tagging). Many are not — and untagged clicks often end up in **Direct** or as meaningless referrals. **UTM parameters** solve this by labeling the link itself.

## The parameters

| Parameter | Meaning | Example |
|---|---|---|
| `utm_source` | Who sent the traffic (the platform or publisher) | `instagram`, `newsletter`, `partner_blog` |
| `utm_medium` | The type of channel | `paid_social`, `email`, `affiliate`, `cpc` |
| `utm_campaign` | The campaign name | `ramadan_sale_2026` |
| `utm_content` | Which creative or link variant | `carousel_v2`, `header_button` |
| `utm_term` | Keyword (mainly paid search) | `running_shoes` |
| `utm_id` | Campaign ID, useful for cost data imports | `cmp_1042` |

GA4 also recognizes `utm_source_platform`, `utm_creative_format` and `utm_marketing_tactic` for more detailed classification.

## How GA4 classifies channels

GA4's **default channel group** assigns sessions to channels such as Organic Search, Paid Search, Paid Social, Organic Social, Email, Affiliates, Referral, Display, Organic Video and Direct, using rules based mainly on **source and medium** values (and whether a campaign name suggests shopping or other patterns). For example, a medium of `email` maps to Email, and paid mediums such as `cpc` combined with a recognized social source map to Paid Social.

This means **your medium values decide your channel reports**. If one person uses `medium=Email`, another `medium=e-mail` and a third `medium=newsletter`, only some will map to the Email channel; the rest end up as Unassigned. Check Google's current default channel group definitions and align your taxonomy to them. You can also create **custom channel groups** for your own reporting needs.

## Build a UTM taxonomy

A taxonomy is a short, enforced list of allowed values:

```
utm_source (platform):   google, meta, instagram, facebook, tiktok, linkedin, youtube,
                         snapchat, x, newsletter, whatsapp, partner_<name>
utm_medium (channel):    cpc, paid_social, organic_social, email, sms, affiliate,
                         influencer, display, referral, qr
utm_campaign:            <objective>_<offer>_<yyyymm>     e.g. leads_freeaudit_202603
utm_content:             <format>_<variant>              e.g. reel_hookA, story_v2
Rules: lowercase only, underscores not spaces, no personal data, no dates in source/medium
```

Publish it in a shared **UTM builder sheet** with dropdowns so nobody types values freehand. The sheet generates the final URL and logs who created it and when.

## When not to use UTMs

- **Internal links on your own site.** UTMs on internal links start a new session and overwrite the original source. Use event parameters to track internal promotions instead.
- **Google Ads with auto-tagging enabled.** The `gclid` parameter handles attribution; adding manual UTMs can conflict unless you know how your setup handles both. Follow current Google Ads guidance for your account.
- **Organic search results.** You do not control those links.

## Special cases

- **QR codes** on packaging or event banners: tag with `utm_medium=qr` and a descriptive source (for example `packaging` or `expo_booth`). Otherwise scans appear as Direct.
- **WhatsApp and messaging apps** often strip referrers, so tagged links are the only way to attribute them.
- **Influencer and creator links**: give each creator a unique `utm_content` or `utm_source` value, plus a discount code for cross-checking.
- **Link shorteners and redirects**: test that UTMs survive every redirect hop.

## Worked example: cleaning a messy report

An education start-up in Lahore finds a large "Unassigned" channel and dozens of mediums such as `Facebook`, `FB`, `social`, `paid`, `Paid-Social`. The fix:

1. Export source/medium pairs for the last 90 days.
2. Map each messy pair to the new taxonomy in a sheet.
3. Launch the UTM builder with dropdowns; retire freehand links.
4. Create a custom channel group to reclassify historical messy values where rules allow, so trend reports are usable.
5. Review Unassigned traffic monthly and fix the source of each leak.

## Hands-on: a builder sheet that refuses bad values

In Google Sheets, put allowed values on a "lists" tab and use data validation dropdowns for source and medium. Then build the URL with a formula that lowercases and cleans the free-text parts:

```text
A: landing URL   B: utm_source (dropdown)   C: utm_medium (dropdown)
D: campaign (free text)   E: content (free text)   F: final URL

F2 =A2 & IF(REGEXMATCH(A2,"\?"),"&","?")
      & "utm_source=" & B2
      & "&utm_medium=" & C2
      & "&utm_campaign=" & LOWER(REGEXREPLACE(TRIM(D2),"[^a-zA-Z0-9]+","_"))
      & IF(E2="","","&utm_content=" & LOWER(REGEXREPLACE(TRIM(E2),"[^a-zA-Z0-9]+","_")))
```

Add a "created by" and "date" column, and protect the lists tab so only the taxonomy owner can edit it.

## Hands-on: find messy values in the BigQuery export

The `collected_traffic_source` record holds the UTM values collected on each event. This query lists source/medium pairs from the last 30 days that are not in your approved list:

```sql
WITH seen AS (
  SELECT LOWER(collected_traffic_source.manual_source) AS src,
         LOWER(collected_traffic_source.manual_medium) AS med,
         COUNT(*) AS events
  FROM `my-project.analytics_123456789.events_*`
  WHERE _TABLE_SUFFIX >= FORMAT_DATE('%Y%m%d', DATE_SUB(CURRENT_DATE(), INTERVAL 30 DAY))
    AND collected_traffic_source.manual_medium IS NOT NULL
  GROUP BY 1, 2
)
SELECT * FROM seen
WHERE med NOT IN ('cpc','paid_social','organic_social','email','sms','affiliate',
                  'influencer','display','referral','qr')
ORDER BY events DESC;
```

Each row is a leak to trace back to a person, agency or tool, and fix at the source.

## Second worked example: a Dubai events company and QR codes

An events company prints QR codes on banners, flyers and badges at an expo. Each placement gets `utm_medium=qr` and a distinct `utm_source` (`expo_banner_hall3`, `flyer_booth`, `badge_back`), with `utm_campaign=expo_leads_202611`. After the event, a single exploration shows which placement drove registrations. Printed codes are tested on three phones before printing, because a typo on 5,000 flyers cannot be fixed with a redirect later unless the code points to a short link you control.

## Common mistakes

- Mixed case (`Instagram` vs `instagram`) creating separate rows.
- Using `utm_source` for the campaign and `utm_campaign` for the platform.
- UTMs on internal banners.
- Forgetting UTMs on email signatures, bios and printed QR codes.
- No owner for the taxonomy, so it drifts within months.

## UTM governance checklist

- [ ] Taxonomy documented with allowed sources, mediums and campaign pattern
- [ ] Builder sheet shared with every person or agency that creates links
- [ ] Mediums aligned with GA4's default channel group rules
- [ ] Redirects and shorteners tested so parameters survive
- [ ] Monthly review of Unassigned and "(not set)" traffic with fixes logged
- [ ] One named owner who approves new values before they are used

## Video lecture: UTM discipline and channel groupings

Lecture coming soon · 15 chapters · about 8 minutes. Read the full transcript below.

1. UTM discipline
2. Why it matters
3. The parameters
4. Medium decides channel
5. A taxonomy
6. When not to use UTMs
7. Special cases
8. Example 1: expo QR codes
9. Example 2: Lahore education startup
10. Watch me do it, part 1
11. Watch me do it, part 2
12. Common mistakes
13. Is it working?
14. Recap
15. Try this now

## Lecture transcript

### UTM discipline

Here's a quick quiz. A customer taps a link in your WhatsApp broadcast, lands on your site and buys. Where does G A four put that sale? If the link wasn't tagged, very possibly in Direct, or as a meaningless referral. Your best-performing channel just became invisible. In this lecture you'll learn how UTM parameters label links, how your medium values decide G A four's channel reports, how to build and enforce a taxonomy, when not to use UTMs, and how to find messy values automatically.

### Why it matters

Why does this matter? Because some sources are detected automatically, like search engines, referrals and Google Ads with auto-tagging. Many aren't: emails, messaging apps, influencer bios, QR codes, many paid social ads. Untagged clicks often land in Direct or Unassigned. Then budget decisions are made on a picture where your email program, your creators or your WhatsApp list look worthless. UTMs are how you make those channels visible.

### The parameters

Here are the parameters. U T M source: who sent the traffic, like instagram, newsletter or partner blog. U T M medium: the type of channel, like paid social, email, affiliate or c p c. U T M campaign: the campaign name. U T M content: which creative or link variant. U T M term: the keyword, mainly for paid search. And U T M id, a campaign id useful for cost data imports. Think of a shipping label: source is the sender, medium is the delivery service, campaign is the order number, content is which box.

### Medium decides channel

Now the key idea: your medium values decide your channel reports. G A four's default channel group assigns sessions to channels like Organic Search, Paid Social, Email, Affiliates, Referral and Direct, using rules based mainly on source and medium. A medium of email maps to Email. But if one person uses capital E Email, another e dash mail, and a third newsletter, only some of them map correctly, and the rest land in Unassigned. Check Google's current channel definitions and align your taxonomy to them.

### A taxonomy

So build a taxonomy, a short, enforced list of allowed values. Sources are platforms, like google, meta, instagram, tiktok, linkedin, youtube, snapchat, newsletter, whatsapp, or partner names. Mediums are channel types, like c p c, paid social, organic social, email, s m s, affiliate, influencer, display, referral and q r. Campaigns follow a pattern, like objective, offer, year and month. Content follows format and variant. Rules: lowercase only, underscores not spaces, no personal data, no dates in source or medium.

### When not to use UTMs

When should you not use UTMs? On internal links on your own site. UTMs on internal links start a new session and overwrite the original source, so use event parameters for internal promotions instead. On Google Ads with auto-tagging enabled, where the g c l i d handles attribution and manual UTMs can conflict unless you know how your setup handles both. And on organic search results, which you don't control anyway. The internal-link mistake is the most common and the most damaging.

### Special cases

Special cases. QR codes on packaging or event banners: tag them with medium q r and a descriptive source, or scans appear as Direct. WhatsApp and other messaging apps often strip referrers, so tagged links are the only way to attribute them. Influencer links: give each creator a unique content or source value, plus a discount code for cross-checking. And link shorteners and redirects: test that UTMs survive every hop. A single redirect that drops the query string silently breaks everything downstream.

### Example 1: expo QR codes

First example, a simple one. An events company in Dubai prints QR codes on banners, flyers and badges at an expo. Each placement gets medium q r and its own source: expo banner hall three, flyer booth, badge back. All share one campaign name. After the event, one exploration shows which placement drove registrations. And they test every printed code on three phones before printing, because a typo on five thousand flyers can't be fixed, unless the code points to a short link they control.

### Example 2: Lahore education startup

Second example, a business case. An education startup in Lahore finds a large Unassigned channel and dozens of mediums like Facebook, F B, social, paid and Paid dash Social. The fix: export source and medium pairs for ninety days, map each messy pair to the new taxonomy, launch a builder sheet with dropdowns, retire freehand links, create a custom channel group to reclassify historical messy values where the rules allow, and review Unassigned every month. Within a quarter, Unassigned shrinks to a sliver.

### Watch me do it, part 1

Watch me build a builder sheet that refuses bad values. On a lists tab, I keep allowed sources and mediums, protected so only the taxonomy owner can edit them. On the main tab, source and medium are dropdowns with data validation, so nobody can type freehand. Campaign and content are free text, but the formula lowercases them and replaces spaces and symbols with underscores. The final column assembles the URL, adding a question mark or an ampersand depending on whether the landing URL already has parameters.

### Watch me do it, part 2

Then I hunt leaks in the BigQuery export. The collected traffic source record holds the UTM values seen on each event. My query takes the last thirty days, lowercases manual source and manual medium, counts events per pair, and keeps only mediums that aren't in my approved list. The output is a ranked list of leaks. The top one is a medium called newsletter from an old email template. I fix the template, and add a note to the change log.

### Common mistakes

Common mistakes. Mixed case, like capital I Instagram and lowercase instagram, creating separate rows. Swapping fields, with the campaign in source and the platform in campaign. UTMs on internal banners. Forgetting UTMs on email signatures, social bios and printed QR codes. And no owner for the taxonomy, so it drifts within months.

### Is it working?

How do you know your UTM discipline is working? Watch two numbers monthly: the share of sessions in Unassigned, and the count of distinct medium values. Both should fall and then stay low. And watch Direct for unexplained jumps after campaigns launch. If Direct spikes when your newsletter goes out, a link somewhere is untagged.

### Recap

Recap. UTMs label links so G A four can attribute traffic that would otherwise be Direct or misclassified. Medium and source values decide the default channel grouping. Enforce a lowercase taxonomy with a builder that uses dropdowns. Never put UTMs on internal links. Test redirects and QR codes. And hunt leaks every month, fixing them at the source.

### Try this now

Try this now. Build a UTM taxonomy and a builder sheet with dropdowns for your organization or a client. Tag five real upcoming links with it, including one QR code if you use print. If you have the BigQuery export, run the leak query, and fix the top leak at its source this week.

## Key takeaways

- UTMs label links so GA4 can attribute traffic that would otherwise be Direct or misclassified.
- Medium and source values decide GA4's default channel grouping.
- Enforce a lowercase taxonomy with a shared builder; never type freehand.
- Never put UTMs on internal links.

## Try it

Build a UTM taxonomy and a builder sheet with dropdowns for your organization or a client, then tag five real upcoming links with it.

- [Previous: QA, debugging and release discipline](https://optimizeall.com/learn/web-analytics-with-ga4/qa-and-debugging)
- [Next: Consent and consent mode concepts](https://optimizeall.com/learn/web-analytics-with-ga4/consent-mode-concepts)
- [All lessons of Web Analytics with Google Analytics 4](https://optimizeall.com/learn/web-analytics-with-ga4)
