← Blog · Essentials · 4 min read
How QR Codes Work — and Why Damaged Ones Still Scan
A QR code looks like noise, but every region of it has a job — and understanding three of those jobs explains almost everything odd about QR behaviour, from why codes survive logos to why cropping the margin kills them.
The three big squares find the code
The corner squares are finder patterns. A phone camera does not know where the code is in the frame, how large it is, or which way up — the three identical squares answer all of that in one pass, which is why a code scans upside down or at an angle. It is also why decorating those squares beyond recognition is the fastest way to break an otherwise healthy code.
Versions: why more data means a finer grid
QR codes come in versions from 21×21 modules up to 177×177. The encoder picks the smallest version that fits your content at your chosen error-correction level — so a short link produces a coarse, easy grid and a long vCard produces a fine one. At the same print size, a finer grid means smaller modules, which is why long content needs to be printed larger to stay readable.
Reed–Solomon: the damage budget
Your data is interleaved with recovery codewords using the same error-correction mathematics as CDs and deep-space links. The four levels — L, M, Q, H — let a reader restore roughly 7%, 15%, 25% or 30% of the codewords from the rest.
That percentage is a budget, and everything spends from it: a logo punched in the middle, a scuff, a fold, glare, a slightly misprinted edge. A logo on level H is comfortable; the same logo on level L may leave nothing in reserve for real-world wear. The single generator here always uses H, which is what lets a logo sit in the middle; the bulk generator lets you choose the level. It is also why the troubleshooting guide lists raising the error-correction level, beside shortening the address and dropping the logo, as a fix for a crowded code.
| Level | Recovers about | Same 47-character address: version · modules | Module at 3 cm |
|---|---|---|---|
| L | 7% | v3 · 29 | 0.81 mm |
| M | 15% | v4 · 33 | 0.73 mm |
| Q | 25% | v5 · 37 | 0.67 mm |
| H | 30% | v6 · 41 | 0.61 mm |
Each step up costs a larger grid, and at a fixed print size a larger grid means smaller modules. From L to H the same address goes from 29 to 41 modules across, and at 3 cm each module shrinks from 0.81 to 0.61 mm. Denso Wave suggests Q or H where codes get dirty, as in a factory, and L in clean conditions with a lot of data to carry.
What this means in practice
Keep the finder squares plain, keep the margin, and treat error correction as insurance you size to the abuse the print will take. A code on a laminated menu lives an easy life at level M, which you can pick in the bulk generator; a code on shipping packaging earns level H, which the single generator always uses. None of this depends on any service being online — the entire mechanism, from finder patterns to recovery, happens between the ink and the phone.
Every code from the single generator is made at level H, the highest.
Make a QR code →