Skip to content
Understanding QR codes

How to Track QR Code Scans in Google Analytics 4

Track QR code scans in Google Analytics 4 for free: tag the link with UTM tags, find the visits in GA4, and fix the Unassigned channel for QR traffic.

Quick answer

Google Analytics 4 can't see the scan itself, but it can see the visit. Add UTM tags (source, medium and campaign) to your web address, make the QR code from that tagged link, and scan it once to test. The visits then appear under Reports, Acquisition, Traffic acquisition. Google Analytics is free.

On this page
  1. Can Google Analytics 4 track QR code scans?
  2. How to track a QR code in GA4, step by step
  3. Which UTM values to use for QR codes
  4. How to test before you print
  5. Why QR traffic shows as Unassigned or Direct
  6. Why GA4 numbers don’t match your scan count
  7. What GA4 can’t track

You printed a QR code, and now you want to know who uses it. Google Analytics 4 (GA4) can show you, and it costs nothing. This guide covers the setup, a test you can run before you print, and why your visits may show up under the wrong name.

Can Google Analytics 4 track QR code scans?

GA4 can’t see the scan itself. It sees visits to your website. If the code opens your site and the link carries tags, GA4 shows each visit and where it came from. Google Analytics is free of charge.

UTM tags are short labels added to the end of a web address. They tell GA4 where a visit came from. A session is one visit to your site. With tags, you can sort sessions by the flyer, poster or card the person used.

A free static code holds the full tagged address inside the code. A dynamic code holds a short link that sends the visitor on to your page. With a dynamic code, the tags must reach your page too.

A free static code has no redirect, so KeptLink cannot count its scans. GA4 can still count the visits to your page, as long as the link has tags.

What you need first

  • A website with GA4 already installed.
  • Access to the GA4 reports for that site.
  • Editor access or above, if you want to make a custom channel group (see the fix below).
  • A phone to test the code.

How to track a QR code in GA4, step by step

Add the tags before you make the code. Test the code before you print it.

Use KeptLink’s free UTM builder, Google’s Campaign URL Builder, or type the tags yourself. Google says to always use these three:

Tag What it labels Example
utm_source Where the link sits flyer
utm_medium The kind of marketing qr
utm_campaign The sale or the campaign fall_sale

For a flyer that links to a sale page, the full address could be:

https://shop.example/sale?utm_source=flyer&utm_medium=qr&utm_campaign=fall_sale

Use lowercase. Google says the values are case sensitive, so qr and QR are two different values. Source is where the link sits, like a flyer. Medium is the kind of marketing. Some sites swap the two, but you should follow Google’s meaning. Google’s URL tagging help lists every field.

For a static code, paste the whole tagged address into the website field. Keep every tag. The website QR code guide shows the steps, and the free website QR code generator is at the end of this page.

For a dynamic code, check that the tags reach your final page. KeptLink adds the tags when it redirects the visitor. You can change them later without reprinting the code.

The static vs dynamic QR code guide covers the wider choice. For GA4 visits alone, a static code is enough when your link will stay the same.

If you make the image in a design app, tag the link first. Then put the tagged link into the code.

Step 3: Test it with your phone

Scan the code and open the page. Check the address for your tags. Then look in GA4 under Reports, then Realtime. Follow the test checklist before you order prints.

Step 4: Print the code

Print only after you have checked the whole path, from scan to tagged page. A static code cannot change once it is printed.

Step 5: Find the visits in Traffic acquisition

In GA4, open Reports, then Acquisition, then Traffic acquisition. This report shows where visits came from. Realtime is faster, but standard reports take longer, so a test visit may show up there later.

Step 6: Pick the right column

A dimension is the label GA4 uses to group the rows of a report. Pick Session source / medium to find flyer / qr. Pick Session campaign to find fall_sale.

These two fields show the visits from your print campaign. Google’s Traffic acquisition help describes the report.

Which UTM values to use for QR codes

Keep one campaign name for one sale. Change the source to tell each print piece apart. These are sample names:

Print piece Source Medium Campaign
Flyer flyer qr fall_sale
Window poster window_poster qr fall_sale
Table card table_card qr fall_sale
Business card business_card qr fall_sale

The columns stand for utm_source, utm_medium and utm_campaign. Use those full tag names in the link.

You can use print as the medium instead of qr. The presets in KeptLink’s dashboard use print. Pick one name and keep it the same on every link, because GA4 reads qr and print as different mediums.

Tell two versions apart with utm_content

Say you print two flyer designs for the same sale. Keep the same source, medium and campaign. Then add utm_content with a different value on each, such as blue_design and white_design. Google says utm_content is for telling creatives apart.

How to test before you print

Test the page as well as the code. A code can open the right page and still lose its tags on the way.

  1. Scan the code with your phone.
  2. Open the page and check that the source, medium and campaign are still in the address.
  3. In GA4, open Reports, then Realtime.
  4. Look for your test visit and the page you opened.
  5. Check the same visit in Traffic acquisition once it shows up there.

Realtime shows the last 30 minutes. Google says it tries to deliver fresh data fast, but it does not promise to.

Watch for the first-user trap. The Realtime cards show how GA4 first found a user. If your phone has visited your site before, a card may show that older source. That alone does not mean your tags failed. Check the final address in the browser, and check the session fields later in Traffic acquisition.

Why QR traffic shows as Unassigned or Direct

Unassigned can mean your tags worked. Google’s default channel rules have no channel for print or QR codes, so GA4 usually puts those visits in Unassigned.

A channel is a group of traffic sources. Google says Unassigned is the value GA4 uses when no channel rule matches the data. Here is what you may see:

You see What it means What to do
Unassigned The tags arrived, but no default channel rule matches them Make a custom channel group with a QR codes channel
(direct) / (none) No tags arrived Tag the link, then scan it and check the address
(not set) At least one UTM field is missing Always set source, medium and campaign

Direct has several causes. A link without tags loses the source. A redirect or a link shortener can strip the tags. Google also says ad blockers can hide where a visit came from. Scan your code, then look at the final address in the browser. If the tags are gone, a redirect may have removed them.

Make a QR codes channel in GA4

You need Editor access or above to make or edit channel groups. Google’s default channel group can’t be edited, so you add a custom one.

  1. In GA4, open Admin.
  2. Under Data display, open Channel groups.
  3. Make a new custom channel group.
  4. Add a channel named QR codes.
  5. Set its rule so that Medium matches qr. If you use both qr and print, add a second rule for print.
  6. Check the order of the channels. Traffic goes into the first channel whose rule it matches.
  7. Save the group.

Match the rule to the values in your real links. A rule for qr alone misses links tagged print.

A custom group works on past data too, so older QR visits get sorted as well. A standard GA4 property can have 2 custom channel groups. The default group still shows Unassigned, because you can’t edit it. Google’s channel group help covers access, rules and limits.

Do not set the medium to referral or link just to land in the Referral channel. It would give your print traffic the wrong label.

Why GA4 numbers don’t match your scan count

GA4 counts a visit when your page loads and GA4 runs on it. A dynamic code’s scan count comes from its redirect. The two counts measure different points on the same trip.

Count Where you see it What it needs
GA4 visits from a QR link Traffic acquisition A tagged visit to a page with GA4
Dynamic code scan count The QR tool dashboard A visit through the code’s redirect

A person may scan the code and leave before your page loads. The scan count sees that person, and GA4 does not. The other way around, an ad blocker can hide the source of a visit, so GA4 files it under Direct. A page that never loads is never counted. Use each count for the question it answers.

A counted visit is very likely a scan, but it is not proof. Treat both numbers as a guide.

When a dynamic code is worth it

Choose a dynamic code if you want scan counts, or if you want to change the tags or the page after printing. With KeptLink, changes reach scanners in about 1 to 2 minutes.

The UTM builder in the dashboard is listed on the paid plans, and a preset fills in the source and the medium for you. KeptLink dynamic codes come with a 14-day free trial. See KeptLink’s scan analytics for what the reports show, dynamic QR codes for how they work, and plans and prices for the cost.

What GA4 can’t track

This method needs a visit to a web page that runs your GA4. Tags alone do not give you access to visits on other sites.

  • A Wi-Fi code does not open your website, so there is no visit to count.
  • A contact card code holds contact details, not a web page.
  • An app store page belongs to someone else, so it is outside your GA4 reports.
  • A page on a site you do not own, such as a form on another service, runs that site’s tracking, not yours.

For those codes, use a dynamic code’s scan count if you want a number.

Make a free QR code from your tagged website address, then test it before you print.

Frequently asked questions

Is Google Analytics free for QR tracking?

Yes. Google Analytics is free of charge. You can use it with a free static code that opens your tagged website page.

Can I track a free static QR code in GA4?

Yes. Put the tags in the web address before you make the code. GA4 then shows the visits that reach your page. A static code has no redirect, so it gives you no scan count.

What should utm_medium be for a QR code?

Pick one value and use it every time, such as qr or print. Google treats the value as case sensitive, so use lowercase. Match that same value in your QR codes channel rule.

Why is my QR traffic Unassigned?

Google's default channel rules have no channel for print or QR codes, so GA4 usually puts those visits in Unassigned. Your tags probably worked. Make a custom channel group to give the visits their own name.

Why does GA4 show fewer visits than my scan count?

A scan counts when the phone reaches the redirect. A GA4 visit counts when your page loads. If someone scans but never waits for the page, only the scan count sees it.

Do I need a dynamic QR code?

No. A static code works for tagged GA4 visits. A dynamic code adds scan counts, and it lets you change the tags or the page after you print.

Does it work on iPhone and Android?

Yes. GA4 does not depend on the phone. The link needs its tags, and your page needs GA4 on it.

Try it now

Make your code right here.

Free, no signup. Everything stays in your browser.

Step 1: What should the code open?

Recommended for print

Your content stays in this browser. KeptLink never receives it.

Step 2: Design it

Templates