← All Articles

How QR Codes Work: Structure and Technology Explained

March 2026 · 7 min read

QR Code (Quick Response Code) is a two-dimensional barcode invented by Japan's Denso Wave in 1994. From checkout counters to mobile payments, restaurant menus to vaccine certificates, QR Codes have become part of everyday life. But have you ever wondered how those black and white squares actually encode and decode information?

Basic QR Code Structure

A standard QR Code contains these key regions:

1. Finder Patterns

The large squares in three corners help scanners quickly locate the QR Code's position and orientation. Each finder pattern is a 7x7 module of nested black and white squares. Scanning works correctly from any angle.

2. Alignment Patterns

Larger QR Codes (version 2+) include additional alignment patterns to correct distortion from skewed printing or curved surfaces.

3. Timing Patterns

Alternating black and white lines connecting the finder patterns, letting the scanner determine module coordinates.

4. Format Information

Contains error correction level and mask pattern data, located near the finder patterns.

5. Data Area

The main body containing the actual encoded data and error correction codes.

Key takeaway: The brilliance of QR Codes is that even when partially obscured or damaged, they can still be read successfully through error correction. This is thanks to the powerful Reed-Solomon error correction codes.

QR Code Versions

QR Codes have 40 versions, from version 1 (21x21 modules) to version 40 (177x177 modules). Higher versions store more data:

VersionModulesMax NumericMax Alphanumeric
Version 121 x 214125
Version 537 x 3715493
Version 1057 x 57652395
Version 2097 x 971,8521,123
Version 40177 x 1777,0894,296

Error Correction Levels

QR Codes use Reed-Solomon error correction codes, providing four levels of fault tolerance:

LevelCodeRecovery CapacityBest For
LowL~7%Clean environments, maximum capacity
MediumM~15%General use (default)
QuartileQ~25%Harsher environments
HighH~30%Logo embedding, outdoor use

Higher error correction levels consume more space, so the same QR Code version stores less data at higher correction levels.

Encoding Modes

QR Codes support multiple encoding modes, automatically selecting the most efficient:

QR Code vs Traditional Barcodes

FeatureTraditional Barcode (1D)QR Code (2D)
Data capacity~20 charactersUp to 7,089 digits
Encoding directionHorizontal onlyHorizontal + vertical
Error correctionNoneUp to 30% recovery
Scan angleMust be horizontally aligned360-degree from any angle
Data typesNumbers/text onlyNumbers, text, URLs, binary
Generate Your QR Code →

Conclusion

Behind the seemingly simple black and white squares lies sophisticated encoding theory and fault-tolerant design. From its 1994 origins in automotive parts tracking to today's ubiquitous digital bridge, the QR Code's success comes from its clever technical design and exceptional practicality.

References

  1. ISO/IEC. "ISO/IEC 18004:2015 — QR Code bar code symbology specification." International Organization for Standardization, 2015. https://www.iso.org/standard/62021.html
  2. Denso Wave. "History of QR Code." Denso Wave Incorporated, 2024. https://www.qrcode.com/en/history/
  3. Reed, I. S. & Solomon, G. "Polynomial Codes Over Certain Finite Fields." Journal of the Society for Industrial and Applied Mathematics, vol. 8, no. 2, 1960, pp. 300-304.
  4. Wikipedia contributors. "QR code." Wikipedia, The Free Encyclopedia, 2025. https://en.wikipedia.org/wiki/QR_code