QR code error correction: how a logo uses up the budget
A QR code survives smudges and folds because it carries extra Reed-Solomon data, and a logo in the middle spends part of that data. Level H, the highest of four levels, can rebuild roughly 30% of the symbol’s data codewords, so a code with a logo should use level H, keep the logo small and keep strong contrast. AlcorQR, our free browser QR designer, enforces those rules, and this write-up explains the reasoning, shows what two published samples decode to and lists what the tool leaves out.
The four levels
Error correction comes in four levels, and each one trades capacity for resilience. As a rule of thumb, L can rebuild about 7% of the data codewords, M about 15%, Q about 25% and H about 30%. The trade-off is density: the same data needs a larger grid at a higher level, so each dot is smaller at a given print size. The encoder on this site shows it. The link https://alcor-industries.com is 28 bytes. At level L it fits a 25 by 25 grid, at M or Q a 29 by 29 grid, and at H a 33 by 33 grid.
What a logo spends
A logo covers modules, the small squares a scanner reads, so the decoder has to rebuild them from the extra data. Glare, folds and smudged print draw on the same budget. The budget does not extend to the three large corner squares, called finder patterns, or to the timing patterns and format information. Those have to survive intact at every level. On a level L code, which can rebuild only about 7%, a logo can use up the whole budget. On a level H code there is far more to spend, but only a fraction of it should go to the logo. That is the reasoning behind the rule: pick level H first, then keep the logo well inside what it can recover.
What AlcorQR does about it
- Locks level H when there is a logo. Without a logo the default is level Q, and you can choose any level. Add a center mark and the editor switches to H and holds it there until you remove the mark.
- Caps the logo at a fifth of the width. The mark can be 8% to 20% of the code’s width, 16% by default, with a backdrop behind it.
- Checks contrast. The dots against the background, and the corner squares against the background, must each reach 3 to 1 before it will export, and it warns below 4.5 to 1. It also warns when the dots are lighter than the background, since light-on-dark codes are less consistently recognized, and it notes that decorative dot shapes and a center mark both reduce tolerance.
- Keeps a safe border. The blank margin around the code is never thinner than 4 modules, even when you change the spacing or the export size.
- Cleans SVG logos. An SVG can carry scripts, links to other sites and embedded pages, so the editor removes scripts, event handlers, animation, stylesheets, embedded media and anything that points outside the file, caps the file at 4,096 elements, and only then draws it. It is never inserted into the page as markup.
- Draws on your device. The link and the logo are not sent to us. You can export a PNG from 512 to 4,096 pixels wide, or an SVG.
What two published samples decode to
Two QR images are published on the site, so both can be checked. The decoding below used a software QR detector, not a phone scanning a printed copy.
- The sample on the AlcorQR page, with rounded dots, purple corner squares and a mark in the middle, decodes to https://alcor-industries.com/alcor-qr/. Its grid is 37 by 37 modules (version 5), the error correction is level H and the mask pattern is 3. The logo is 14% of the code’s width. Its backdrop spans about a fifth of the width and about 4% of the area, and the code still decodes with the backdrop in place. That check rebuilt the grid from the SVG’s shapes, so it tests the geometry, not a rendered export. At level L the same link would fit a 29 by 29 grid.
- The older sample on the AlcorQR app card, dark modules on a cream panel with the Alcor star in the middle, decodes to https://alcor-industries.com. It is 33 by 33 modules (version 4), level H and mask pattern 6, and its center tile is about 7 modules wide, around 4.5% of the symbol’s area.
What it does not do
- No dynamic codes. The link is encoded in the code itself, so a printed code cannot be pointed somewhere else later. If the destination may change, encode an address you control and redirect from there.
- No scan analytics, dashboards or bulk generation. Nothing about the code is sent to us, so there is nothing to count.
- A payload limit. The editor refuses more than 1,200 bytes. Shorter links make a smaller, less dense code that is easier to scan.
- No promise that every styled code scans. Colors, paper, print size, logo size and the scanning app all matter. Print one at full size on the real material and try it with more than one phone before a print run. I have no scan-rate data from printed samples to publish.
- No account and no checkout. It is free to use, including for business.
If you want the code designed for a print job
Want a code designed and tested for a specific job, such as a menu, a truck or packaging? Tell me where it will be printed and what it should open, and you get a written quote before any work starts. See what we build for operations, or get a written quote. To try the designer yourself, open AlcorQR.