How do QR Codes work? A detailed breakdown
What happens when you scan a QR Code? Get the story behind the shape, how they are generated, how scanning works and more.
If you’ve ever wondered how it's possible to scan a square from your smartphone and then be directed to detailed information on the internet, you've come to the right place. Let’s unpack how QR codes work and how to scan them.
What is a QR Code?
QR is short for Quick Response and aptly named by its founders for the ability to quickly share and store data. The square you see as a QR Code is a two-dimensional barcode. Unlike traditional barcodes that are read in one direction - from left to right, a QR Code can be read in two directions - both vertically and horizontally. This allows them to store a lot more information than 1D barcodes.
A standard QR Code can store up to 4,000 characters of information, including URLs, contact details and even Wi-Fi credentials. This makes them incredibly useful for both personal and business digital tasks.

Why is a QR Code Square?
You'll notice that each design includes dots and patterns. These aren't just decorative elements but data carriers with a unique job. Let's break down the key parts:
Position markers: The large squares found in three of the four corners. They help scanners detect the position of the code so it's read correctly from any angle.
Alignment marker: A smaller square usually closer to the bottom right of larger QR Codes. It helps the scanner adjust if the code is captured from a warped angle or if the visual is slightly distorted.
Timing pattern: The dotted line of alternating black and white modules between the position markers. It allows the scanner to figure out the size and shape of the grid.
Data modules: The tiny dots scattered throughout the QR Code. They contain the actual information, converted into binary (ones and zeros).

How does QR Code scanning work?
When you point your phone’s camera at a QR Code, here’s what happens:
Detection: The camera identifies the position markers in the corners. This tells the device where the QR Code starts and ends.
Decoding: The scanner calculates the angle using the alignment and timing patterns. It then reads the data modules line by line.
Binary conversion: The code’s patterns are translated into binary code (a series of ones and zeros).
Execution: Once the information is decoded, the result is shown on your screen. It could be a link, contact card or payment portal.
All of this happens in less than a second. And if some parts of the code are damaged, blurred, or covered by a logo, error correction kicks in to fill in the missing pieces so QR Codes generally have a high functionality rate and are widely used across industries.
