technical-guides

QR Code Error Correction Levels Explained

Understand the four QR code error correction levels (L, M, Q, H) and how to choose the right one for your use case.

SmartyTags TeamJanuary 20, 202612 min read

What Error Correction Actually Does

Every QR code contains more data than strictly necessary. The extra data is redundant information, mathematically generated, that allows a scanner to reconstruct the code's content even if part of the code is damaged, dirty, or obscured. This built-in redundancy is called error correction, and it is one of the reasons QR codes are so much more reliable than traditional barcodes.

The error correction system uses Reed-Solomon codes, which is the same mathematical approach used in CDs, DVDs, and deep-space communication. When a phone camera scans a QR code, the decoder does not just read the data. It verifies it against the redundant information and automatically corrects any errors it finds, up to the limit defined by the error correction level.

This is not an abstract technical detail. It has direct, practical implications for how you design, print, and deploy QR codes. Choosing the right error correction level affects the code's size, the amount of data it can hold, and how resilient it is to real-world damage.

The Four Error Correction Levels

QR codes support four error correction levels, designated by single letters. Each level defines the maximum percentage of the code that can be damaged while still remaining scannable.

Level L (Low) - 7% Recovery

Level L provides the minimum error correction. Up to 7% of the code's data modules can be damaged or obscured, and the code will still scan correctly.

Best for:

  • Digital-only display (screens, websites, apps) where physical damage is not a concern
  • Codes that encode very long URLs where you need to minimize the physical code size
  • Temporary, controlled environments where the code will not be exposed to wear

Trade-off: Smallest physical code size for a given amount of data. Least resilient to damage.

Level M (Medium) - 15% Recovery

Level M is the default for most QR code generators and the most commonly used level. It tolerates up to 15% damage.

Best for:

  • Standard printed materials (brochures, flyers, business cards)
  • Indoor signage in controlled environments
  • Product labels that will not be exposed to harsh conditions
  • Most general-purpose applications

Trade-off: A good balance between code size and resilience. This is the right choice when you have no specific reason to choose otherwise.

Level Q (Quartile) - 25% Recovery

Level Q provides strong error correction, tolerating up to 25% damage. The code is noticeably larger than an equivalent Level M code.

Best for:

  • Outdoor signage exposed to weather, UV, and physical wear
  • Product packaging that will be handled, stacked, or shipped
  • Codes with logo overlays that obscure part of the pattern
  • Industrial environments (warehouses, factories, construction sites)
  • Materials that will be folded, such as direct mail pieces

Trade-off: Larger code size, but significantly more resilient. If your code will face any physical stress, this is a strong default choice.

Level H (High) - 30% Recovery

Level H is the maximum error correction available. Up to 30% of the code can be damaged, and it will still scan.

Best for:

  • Codes with large logo overlays in the center
  • Extreme environments (outdoor exposure over months, industrial settings)
  • Codes printed on materials prone to damage (labels on bottles that get wet, stickers on equipment)
  • High-stakes applications where scanning failure is unacceptable and code size is not a constraint
  • Art or design-heavy QR codes where significant portions of the pattern are stylized

Trade-off: Largest code size. For a given amount of data, a Level H code is substantially larger than a Level L code. This limits how much data you can encode in a given physical space.

How Error Correction Affects Code Size

This is the core trade-off, and understanding it is essential for making good decisions.

A QR code has a fixed grid of modules (the small squares that make up the pattern). The grid size is called the "version," ranging from Version 1 (21x21 modules) to Version 40 (177x177 modules). The version determines how much total data the code can hold.

Higher error correction levels consume more of that capacity for redundancy, leaving less room for actual data. This means that for the same URL, a code with Level H error correction needs a larger version (more modules, larger physical code) than a code with Level L.

Practical example: Encoding a 50-character URL:

  • Level L: Version 3 (29x29 modules)
  • Level M: Version 3 (29x29 modules)
  • Level Q: Version 4 (33x33 modules)
  • Level H: Version 4 (33x33 modules)

The difference becomes more pronounced with longer URLs:

Encoding a 100-character URL:

  • Level L: Version 5 (37x37 modules)
  • Level M: Version 5 (37x37 modules)
  • Level Q: Version 6 (41x41 modules)
  • Level H: Version 7 (45x45 modules)

More modules means each individual module is smaller at the same overall code size. Smaller modules are harder for cameras to resolve, especially older cameras. So there is a cascading effect: higher error correction leads to more modules, which leads to smaller modules, which leads to harder scanning at the same physical size. Compensate by making the code physically larger.

Choosing the Right Level: A Decision Framework

Ask these questions in order:

1. Will the code have a logo overlay? If yes, use Level Q minimum. If the logo covers more than 15% of the code area, use Level H. The logo is functionally "damage" to the code pattern, and the error correction is what allows it to scan despite the obstruction.

2. Will the code be printed on a physical surface exposed to wear? If yes, move up at least one level from L. Outdoor signage, product packaging, direct mail, and any material that will be handled gets Level Q or H. For indoor, controlled environments, Level M is sufficient.

3. Is the code temporary or permanent? Temporary codes (event signage, seasonal promotions) face less cumulative wear. Level M is usually fine. Permanent codes (equipment labels, building signage, product packaging) should use Level Q or H.

4. Is the URL short or long? Short URLs produce smaller codes at any error correction level. If you are encoding a compact URL (which you should be, by using short links or dynamic QR codes from a platform like SmartyTags), you have more room to increase error correction without impacting scanability.

5. Is the code size constrained? If you are printing on a business card or small label with limited space, you may need to use Level M or even Level L to keep the code compact enough to print at a scannable size. In space-constrained situations, shortening the URL is better than lowering the error correction level.

The Relationship Between Error Correction and Dynamic QR Codes

Dynamic QR codes encode a short redirect URL rather than your final destination URL. Because the redirect URL is compact (often under 30 characters), the resulting QR code has fewer modules, which means:

  • The code is physically smaller at any error correction level
  • You can use higher error correction without increasing the code size significantly
  • Each module is larger, making the code easier to scan

This is one of the underappreciated advantages of dynamic QR codes. By keeping the encoded URL short, you free up capacity for error correction. You get a smaller, more scannable, more resilient code.

Create a dynamic QR code to see this in practice. The code will be more compact than one encoding a full-length URL directly.

Logo Overlays and Error Correction

Adding a logo to the center of a QR code is popular for branding, but it works only because of error correction. The logo physically replaces code modules, and the error correction system reconstructs the missing data.

Guidelines for logo overlays:

  • Level Q (25%): Safely supports a logo covering up to 15-20% of the code area. The remaining 5-10% of error correction handles other potential damage.
  • Level H (30%): Safely supports a logo covering up to 20-25% of the code area.
  • Levels L and M: Not recommended for logos. Level L gives you only 7% total capacity, and a logo of any meaningful size will exceed that. Level M at 15% leaves almost no margin for additional damage.

Positioning matters. Place the logo in the center of the code, avoiding the three corner position markers (the large squares in three corners) and the alignment patterns. These are critical for the scanner to orient the code and should never be obscured.

Always test. Error correction mathematics guarantee recovery up to the stated percentage, but in practice, the distribution of damage matters. A logo that happens to cover a particularly dense data region may cause issues even within the theoretical limit. Test before printing.

Real-World Scenarios

Scenario 1: Restaurant Table Tent

A restaurant prints QR codes on laminated table tents for menu access. The codes are indoors, in a controlled environment, and the lamination protects from spills.

Recommendation: Level M. The environment is low-risk, and the lamination provides physical protection. Level M gives enough resilience for minor wear while keeping the code compact.

Scenario 2: Outdoor Real Estate Sign

A real estate agent puts a QR code on a yard sign linking to a property listing. The sign will be outdoors for weeks or months, exposed to sun, rain, and potential vandalism.

Recommendation: Level Q or H. UV exposure fades ink, rain can cause smearing on non-laminated surfaces, and prolonged outdoor exposure invites accumulated damage. Level Q provides strong resilience; Level H if the sign will be out for more than a month.

A consumer brand wants a QR code with their logo on the product box. The box will be shipped, handled, and stored.

Recommendation: Level H. The logo overlay consumes a significant portion of the error correction budget, and shipping and handling will add wear. Level H gives maximum room for both the logo and physical damage.

Scenario 4: Conference Slide Presentation

A speaker displays a QR code on a presentation slide for the audience to scan and access resources.

Recommendation: Level L or M. There is zero risk of physical damage. The code is displayed on a high-resolution screen. The only concern is making the code large enough for audience members to scan from their seats. Use Level L for the smallest visual footprint on the slide, or Level M for a small safety margin.

Scenario 5: Gym Equipment Label

A gym sticks QR codes on equipment linking to instructional videos. The labels face humidity, occasional wiping with cleaning solution, and constant proximity to sweat.

Recommendation: Level Q. The environment is harsh for printed materials, but the codes are scanned from close range. Level Q provides resilience against smudging and cleaning damage. See our guide on QR codes for gyms for more fitness-specific applications.

Technical Deep Dive: How Reed-Solomon Works

For those who want to understand the mathematics, here is a simplified explanation.

QR codes divide their data into blocks and generate error correction codewords for each block using Reed-Solomon polynomial division. The original data is treated as coefficients of a polynomial. This polynomial is divided by a generator polynomial, and the remainder becomes the error correction codewords.

When a scanner reads the code, it uses the error correction codewords to detect and locate errors. The key mathematical property is that with n error correction codewords, the system can:

  • Detect up to n errors
  • Correct up to n/2 errors (when positions are unknown)
  • Correct up to n errors (when positions are known, called "erasures")

The four error correction levels simply specify how many error correction codewords are generated relative to the data codewords. Level H generates approximately the same number of error correction codewords as data codewords, which is why it can recover from 30% total damage.

This is the same math that allows CDs to play even with scratches on the surface. It is well-proven and extremely reliable.

Common Questions

Can I change the error correction level after generating a code? No. The error correction level is baked into the code at generation time. Changing it produces a completely different QR code pattern. If you need a different level, generate a new code.

Does higher error correction make codes scan faster? No. Scanning speed is primarily determined by code size, contrast, and camera quality. Error correction level affects resilience, not speed.

Can I tell what error correction level a code uses by looking at it? Yes, technically. The format information near the corner position markers encodes the error correction level. But in practice, you would need to decode those specific modules, which is not something you can do by eye. Use a QR code analysis tool or check the settings in your generator.

Should I always use Level H to be safe? No. Level H produces the largest codes and holds the least data. It is overkill for controlled, digital, or indoor environments. Match the level to the actual risk level of your deployment environment.

Recommendations Summary

Use CaseRecommended Level
Digital display onlyL
Standard indoor printM
Direct mail and flyersM or Q
Outdoor signageQ or H
Product packagingQ or H
Code with logo overlayQ or H
Industrial/harsh environmentH
Business cards (small print)M (with short URL)

Next Steps

Understanding error correction is one piece of creating reliable QR codes. For the full picture, combine this knowledge with proper testing before printing, smart placement decisions, and effective calls to action.

Visit SmartyTags to create QR codes with your preferred error correction level, or explore the features and pricing to see how the platform supports your needs.

SmartyTags Team

Content Team

The SmartyTags team shares insights on QR code technology, marketing strategies, and best practices to help businesses bridge the physical and digital worlds.

Related Articles

Stay up to date

Get the latest QR code tips, guides, and product updates delivered to your inbox.

No spam. Unsubscribe at any time.