Error Correction
Error correction is a mechanism that can restore the original data even if part of a QR code becomes dirty or damaged. It is achieved through a mathematical algorithm called the Reed-Solomon code.
There are four levels of error correction.
- L: Can restore about 7% of the data. Chosen when you want to maximize data capacity
- M: Restores about 15%. The default for general use
- Q: Restores about 25%. For environments prone to dirt, such as outdoor displays
- H: Restores about 30%. Essential for design QR codes with an overlaid logo
The higher the level, the greater the restoration capability, but because redundant data increases, the QR code size (version) becomes larger even for the same amount of information. For example, when storing a 100-character URL, level L needs only version 5 (37 by 37 modules / 106 bytes in byte mode), but level H requires version 10 (57 by 57 modules / 119 bytes in the same mode). Choosing the right level for the use case determines the balance between reading accuracy and code size.