Technology

What Size Should a QR Code Be?

What Size Should a QR Code Be?

Most QR codes that fail in the wild are not badly generated. They are badly sized. Someone designed one on a monitor, where everything is close and brightly lit, and then printed it at a size that made sense in the layout rather than a size that made sense to a camera three metres away.

Sizing a QR code is genuinely simple once you know the one ratio that governs it.

The ten to one rule

A QR code needs to be at least one tenth as wide as the distance it will be scanned from. That is the whole rule, and it scales cleanly from a business card to a billboard.

  • Scanned at 30cm (a card in the hand): 3cm code
  • Scanned at 1m (a table tent, a menu): 10cm code
  • Scanned at 2m (a shop window, a poster): 20cm code
  • Scanned at 5m (a wall display, a banner): 50cm code
  • Scanned at 20m (a billboard): 2m code

The ratio is conservative on purpose. It assumes an ordinary phone, held by someone not especially steady, in light that is not ideal. Modern flagship cameras beat it comfortably. Five-year-old handsets do not, and those are the ones that matter, because a code only has to fail once for someone to give up.

The absolute floor

Below about 2cm, codes become unreliable regardless of the ratio. Printers spread ink, paper absorbs it, and modules that measure a fraction of a millimetre start bleeding into their neighbours.

Treat 2cm as a hard minimum for anything commercially printed, and 3cm as the sensible working minimum. If your layout cannot accommodate 2cm, the honest answer is that the piece does not have room for a QR code, and a short memorable web address will serve people better.

Why data length changes everything

Two codes printed at the same physical size can behave completely differently, because size in centimetres is not the measurement that matters. Module size is.

A QR code is a grid, and the grid gets finer as you add data. The smallest version is 21 modules across. The largest is 177. Print both at 3cm and the first has modules about 1.4mm wide, while the second has modules under 0.2mm, which is finer than many printing processes can hold.

So the practical rule underneath the ten to one rule is: shorten the data and you can shrink the code. Encoding a 30 character link instead of a 120 character one with tracking parameters can drop several versions and roughly double your module size at the same printed dimensions.

Aim for modules no smaller than 0.4mm in print. Below that you are relying on luck and good lighting.

Don’t forget the margin

The quiet zone is four modules wide on every side, and it counts as part of the space the code occupies. A 3cm code actually needs closer to 3.6cm of clear area.

Designers routinely allocate exactly the code’s dimensions and butt the artwork straight up against it. That crops the quiet zone and breaks codes that were otherwise sized correctly, which is a frustrating way to lose a print run.

Screens are a different problem

On a screen, the ten to one rule still holds, but you are working in pixels and you have a new failure mode: scaling.

A QR code resized by a browser or a slide deck gets interpolated, which blurs the hard edges the decoder depends on. Always render at a whole multiple of the module size and display at exactly that size. Roughly 10 pixels per module is comfortable; below about 4 it becomes fragile.

Use PNG or SVG, never JPEG. JPEG compression is designed for photographs and introduces soft halos around exactly the sort of high contrast edges a QR code is made of.

And if the code is going on a slide, remember the audience is scanning from the back of the room, not from the presenter’s laptop. That is a 10m distance, which means a 1m code, which in practice means most conference slides should not have a QR code on them at all.

Awkward surfaces

  • Curved packaging. Keep the code within about a third of the circumference, and size up, since curvature costs you effective resolution.
  • Fabric. Weave texture eats fine detail. Go at least fifty percent larger than the rule suggests.
  • Vehicles. People scan moving or briefly, so size for the furthest realistic distance and then add margin.
  • Windows. Reflections cost you more than distance does. Size generously and consider the viewing angle.
  • Engraving and embossing. Contrast comes from shadow, which changes with the light. Test in the actual installed lighting.

A quick sanity check

Print the code at its intended size. Stand at the intended distance. Scan it with the oldest phone you can find, indoors, without moving closer.

If it reads within about two seconds, the size is right. If you find yourself stepping forward, it is too small, and stepping forward is exactly what a real customer will not do.

When you regenerate, our URL QR code generator runs in the browser and produces a clean, unscaled image you can place at whatever size the rule calls for.

Join the discussion

Held for review before it appears. Links are not allowed and your email is never published.