QR error correction is built-in redundancy that lets a QR code still scan when part of it is dirty, damaged or covered. There are four levels: L recovers about 7% of the data, M about 15%, Q about 25% and H about 30%. Higher levels are more robust but make the code denser.
How QR error correction works
A QR code does not just store your text once and hope for the best. When the code is created, the data is split into blocks of bytes called codewords, and extra error-correction codewords are calculated and added. This uses a mathematical method called Reed–Solomon error correction, the same family of techniques used for decades in CDs, DVDs and data transmission.
When a phone scans the code, it reads all the codewords. If some are unreadable or wrong because of a scratch, a stain or a logo on top, the scanner uses the extra codewords to work out what the missing parts must have been. As long as the damage stays within what the level can handle, the scan succeeds and you never notice anything was wrong.
The error correction level is recorded in a small area of the code called the format information, which is stored twice so the scanner can read it reliably.
The four levels: L, M, Q and H
Each level trades storage space for robustness. The percentages below are approximate amounts of the code's data that can be restored.
- Level L (Low), about 7%. The most data in the smallest code. Good for clean, indoor, screen-based uses where damage is unlikely.
- Level M (Medium), about 15%. A balanced, common default. Suitable for most printed materials such as flyers, menus and business cards.
- Level Q (Quartile), about 25%. Extra protection for codes that may get dirty or worn, such as on packaging, labels or in workshops.
- Level H (High), about 30%. Maximum robustness. Often chosen for outdoor signs, harsh environments, or codes with a logo placed in the middle.
These figures describe recoverable data, not "you can cover 30% of the picture". Damage in the wrong place, especially over the three large corner squares, can stop a code from scanning even if the total area affected is small.
The trade-off: robustness versus density
Error correction is not free. The extra codewords take up space inside the code. For the same content, a higher level means:
- More modules, the small black and white squares
- A larger QR "version", which ranges from 21 × 21 modules at version 1 up to 177 × 177 at version 40
- Smaller individual squares when printed at the same physical size
Smaller squares are harder for cameras to resolve, especially from a distance, in low light or on older phones. So choosing level H for a long web address on a tiny label can make the code less reliable, not more.
The fix is usually to reduce the data. A short link, such as the qr-th.com/r/ links used by QR-TH dynamic codes, keeps the content short. That leaves room for a higher error correction level without making the code overly dense. Our guide to static vs dynamic QR codes explains how short links work.
Which level should you choose?
Use this simple guide:
- Shown on a screen or clean indoor print? Level L or M is enough.
- Ordinary printed marketing, such as menus, flyers or posters? Level M is a reliable default.
- Likely to get scuffed, wet, dirty or partly covered? Choose Q.
- Logo in the centre, outdoor sign or harsh conditions? Choose H, and keep the data short.
- Whatever you choose, test the printed code on several phones at the real distance and lighting.
Many QR generators pick a sensible level automatically, often raising it when you add a logo. If your tool lets you choose, think about where the code will live rather than always maximising it.
Error correction and logos
Placing a logo in the middle of a QR code works because of error correction: the logo hides some modules, and the scanner reconstructs them from the redundant data. A few rules keep it reliable:
- Use level H, or at least Q, when adding a logo.
- Keep the logo reasonably small and centred. Leave plenty of margin below the maximum recovery level, because real-world damage, glare and blur also use up the error budget.
- Never cover the three large finder squares in the corners or the quiet zone around the code.
- Keep strong contrast between the code and the background.
For more design advice, read our article on QR code design best practices.
What error correction cannot fix
Error correction is powerful, but it has limits. It will not rescue a code that has:
- Poor contrast, such as light grey on white or dark on dark
- No quiet zone, because the code is printed right up against other graphics
- Damaged finder patterns in the corners
- Squares too small to resolve at the scanning distance
- Heavy distortion, for example on a strongly curved surface
- Reflections from glossy lamination that wash out large areas
Error correction also does not make a code more secure. A QR code with level H can still point to a dangerous website, and a scam sticker placed over a genuine code will scan perfectly. If you are unsure about a code, scan the QR code online with QR-TH first to see the destination before anything opens.
FAQ
What is the best QR error correction level?
There is no single best level. M is a good default for most printed uses, while H suits logos and outdoor or harsh conditions. Choose based on where the code will be used.
Does a higher error correction level make a QR code bigger?
For the same data, yes. It adds more modules, so either the printed code gets larger or the individual squares get smaller.
Can I put a logo on any QR code?
Only if there is enough error correction to cover the hidden area, so use Q or H. Keep the logo small and away from the corner squares, and always test before printing.
Can I change the error correction level after printing?
No. The level is part of the printed pattern. To change it, you must generate and print a new code.
Want a code that stays readable in the real world? Create one with QR-TH's free QR code generator, keep the content short, and test it on a couple of phones before you print.