UTM Codes for QR Codes: How to Tag Printed Codes So Every Scan Counts
Add UTM codes to a QR code so scans show up under the right campaign in Google Analytics: which parameters to use, what values suit print, where they go and how to fix them after printing.


To track a QR code with UTM codes, add utm_source, utm_medium and utm_campaign to the web address the code opens. When someone scans the code, Google Analytics reads those parameters and files the visit under your campaign instead of direct traffic. Use a dynamic QR code, so a wrong value can be fixed after the code is printed, and give each placement its own code, so you can compare a poster with a flyer.
Facts about Google Analytics below come from Google's help pages as they read on October 28, 2026.
Why QR code scans show up as direct traffic
A scan opens your page from a camera app, not from another website, so there is no referring page to report. Google's documentation says that "a session is processed as direct traffic when no information about the referral source is available" (source).
That puts your poster, your packaging and your trade show booth in the same bucket as people who typed your address or used a bookmark. UTM codes give the visit a source, a medium and a campaign before it reaches your site, so Google Analytics can tell a scan apart from those visits.
The UTM parameters a QR code needs
Google's guide to campaign parameters is direct about the minimum: "When you add parameters to a URL, you should always use utm_source, utm_medium, and utm_campaign." The other two are optional:
- utm_source is the referrer. Google's own examples are "google, newsletter4, billboard."
- utm_medium is the marketing medium, such as "cpc, banner, email" in Google's examples.
- utm_campaign is the product, slogan or promo code, for example "spring_sale."
- utm_content differentiates creatives. For print, that means two versions of the same piece.
- utm_term is meant for paid keywords, so a printed QR code rarely needs it.
How to choose values for printed QR codes
Google lists billboard as an example source, and that fits print: the source is where the code physically is.
- utm_source: the place or publication, such as main-street-store, expo-booth or city-magazine.
- utm_medium: one value for all printed codes, such as qr. Use it everywhere, without variations.
- utm_campaign: the promotion, such as spring-menu.
- utm_content: the piece or spot, such as table-tent, receipt or window-poster.
A café promoting a spring menu on its table tents would point the code at an address like https://example.com/menu?utm_source=main-street-store&utm_medium=qr&utm_campaign=spring-menu&utm_content=table-tent. A second code on the receipts would change only utm_content.
Where Google Analytics puts utm_medium=qr
GA4's default channel group has rules for mediums such as email, display and referral, but none for qr, print or offline. In Google's words, "Unassigned is the value Analytics uses when there are no other channel rules that match the event data." So scans tagged with a medium like qr appear under Unassigned in channel reports.
The source, medium and campaign values are still recorded, so the scans are easy to find by those values. If you want them in a named channel, the same page explains that "Default channel groups can't be edited in Google Analytics. You have the option to create custom channel groups."
Don't borrow a medium such as email or display just to land in a named channel. Your print results would then be counted inside those channels' reports.
Write every value the same way
Google is explicit: "Parameter values are case sensitive." It recommends that you "maintain a strict, case-sensitive naming convention for all fields such as source, medium, and campaign." QR and qr become two different mediums, and Spring-Menu and spring-menu two campaigns.
Pick one style, such as lowercase words joined by hyphens, and write it down before the first code goes to print. CodeQR stores the values exactly as typed, so its reports split them the same way. How to name links and QR codes has a convention you can adapt.
Put the UTM codes in the destination, not on the short link
A dynamic QR code holds a short link, and the short link redirects to your destination. The UTM codes belong in that destination URL.
In CodeQR, the UTM Builder section of the QR code editor adds them for you, on every plan, or you can paste a destination URL that already contains them. The values are stored with the code. Parameters added to the short link itself still reach your site, but CodeQR's UTM report doesn't read them. Add UTM parameters to a short link covers both cases.
A static QR code works differently. The full address, UTM codes included, is drawn into the image, so the values are fixed once it is printed. In CodeQR, the UTM Builder is available only for dynamic QR codes.
Why a dynamic QR code is safer for UTM codes
A typo in utm_campaign on a static code lives on every printed copy. With a dynamic QR code, you open the code, fix the destination and keep the print run. Change where a QR code goes after printing shows how.
Editing UTM values changes how past scans are labeled too. CodeQR's report reads the values currently stored on the code, so earlier scans move to the new values. That helps when you fix a typo. When you start a new campaign, create a new code instead of reusing the old one.
A dynamic code also counts scans in CodeQR, whether or not the page loads Google Analytics. A static code is never seen by CodeQR at all, because the scan goes straight to the address in the image.
One QR code per placement
One code carries one set of UTM values. To compare the window poster with the receipt, each needs its own code with its own utm_source or utm_content. Using one code everywhere gives you a total, but you can't tell which placement brought the scans.
Name the codes the way you name the values, so the list of codes in your dashboard reads like the list of placements.
How to build the tagged URL
- In CodeQR, turn on the UTM Builder when you create a dynamic QR code and fill in Source, Medium, Campaign, Content and Term. The UTM builder page has an overview.
- Google's Campaign URL Builder builds the same URL, which you can paste in as the destination.
For background on UTM parameters beyond QR codes, see UTM parameters: how to track campaigns and optimize results.
Reading the results in CodeQR and in Google Analytics
CodeQR's UTM Report lists one row per link or QR code with its Source, Medium, Campaign, Content and Term, and separate columns for clicks, scans and the total. You can export it as a CSV. The full report is available on Pro and above; Free and Starter see a preview.
In Google Analytics, the same values show up on the sessions that follow each scan, next to the rest of your traffic. Expect the two numbers to differ: CodeQR counts the scan at the redirect, and Google Analytics counts a session only once its tag runs on your page.
Checklist before you print
- utm_source, utm_medium and utm_campaign are set, written in your agreed style.
- The medium is the same on every printed code.
- The code is dynamic, so a mistake can be fixed after printing.
- Each placement has its own code.
- You scanned a test print with a phone and found the visit in Google Analytics under the right campaign.
UTM codes for QR codes: questions
Yes. Add the UTM parameters to the destination URL the QR code opens. With a dynamic QR code, the code holds a short link and the UTM codes live in its destination, so you can change them after printing.