May 8, 2026 · 4 min read

QR Codes for Campaign Tracking: The Offline Link You Can Measure

QR codes bridge offline and online marketing. Here's how to track them with UTM parameters and what data you actually get back.

links analytics strategy

The gap in your tracking

You run digital campaigns. You tag everything. You can tell your CMO exactly how many clicks came from the LinkedIn ad versus the newsletter.

Then someone puts a URL on a trade show banner. Or a product insert. Or a direct mail piece. And the tracking stops. That visitor shows up in GA4 as "direct" because they typed the URL or scanned a bare QR code with no parameters attached.

QR codes fix this. But only if you set them up right.

How QR code tracking works

A QR code is just a URL encoded as an image. Scan it, and your phone opens that URL in the browser. That's it.

The tracking part comes from what you put in the URL. Tag it with UTM parameters before you generate the QR code, and every scan gets attributed like any other campaign click.

Example: you're putting a QR code on product packaging for a spring promotion.

The URL: https://yoursite.com/spring?utm_source=packaging&utm_medium=qr&utm_campaign=spring-2026

Generate the QR code from that tagged URL. Every scan now shows up in your analytics under source=packaging, medium=qr, campaign=spring-2026. Not "direct." Not "(not set)."

What data you get from a QR scan

When someone scans a QR code that points to an Attri short link, the redirect captures:

  • Country and city from the IP address
  • Device type (almost always mobile, which tells you something about context)
  • Browser (Safari, Chrome, Samsung Internet)
  • Timestamp (when they scanned, not when you printed)
  • UTM parameters you tagged the URL with

You won't get referrer data since QR scans don't have a referrer. That's why the UTM parameters matter more here than anywhere else. Without them, a QR scan is invisible.

Always shorten the URL before generating the QR code. Two reasons.

First, shorter URLs make simpler QR codes. A 40-character URL generates a QR code with fewer modules (dots) than a 160-character UTM-tagged URL. Simpler QR codes scan faster and more reliably, especially on low-res prints or from a distance.

Second, if you ever need to change the destination, you can update the short link without reprinting the QR code. Product already shipped with the wrong landing page URL? Update the redirect. The QR code still works.

Common QR code mistakes

No UTM parameters. The most common one. Someone generates a QR code from a bare URL and the scans show up as direct traffic. Always tag before generating.

Tiny QR codes. If the code is smaller than 2cm x 2cm, some phones struggle to scan it. Bigger is better for print. Test it from arm's length before approving the design.

No fallback. Print the short URL as text near the QR code. Not everyone scans. Some people prefer to type. go.yourcompany.com/spring is memorable and works as both a QR target and a typeable link.

Dark backgrounds. QR codes need contrast. Dark code on light background works. Light code on dark background works too if the colors are inverted properly. But a QR code printed over a busy photo is going to fail.

Where QR codes work best

Product packaging. Insert cards, labels, boxes. Every scan is a customer who already bought your product. That's a high-intent audience worth tracking.

Events. Badges, booth signage, presentation slides. Tag each placement differently with utm_content so you know whether the badge or the booth drove more scans.

Print ads and direct mail. The only way to measure offline print. Tag each publication or mail drop separately.

Receipts and invoices. Drive customers to a review page, a referral program, or a reorder flow. QR on a receipt is surprisingly effective because the timing is right after purchase.

The setup

Build your tagged URL with the UTM builder. Shorten it with Attri (or any shortener). Generate the QR code. Attri generates QR codes from every short link automatically, downloadable as PNG or SVG.

Tag it, shorten it, generate it, print it. The scan data flows into your analytics like any other click.

← All posts