Will We Ever Run Out of QR Codes? The Math and the Real Limits
By OwnQR · Published · Updated
Quick answer: Not in any practical sense. A QR code is a way of encoding information, not a unique number withdrawn from a worldwide stockpile. The number of possible encoded messages is extraordinarily large. More importantly, the same QR pattern can be generated and used again without preventing anyone else from making a code. What can run into limits is a particular short-link service, its identifier system, or the website behind a QR code.
That distinction is easy to miss. Claims that “80% of QR codes are already used” do not describe any verified worldwide allocation system. When someone asks whether codes are running out, they could mean three very different things: black-and-white patterns, information that fits in a QR symbol, or short URLs assigned by a company. Those are not interchangeable numbers.
For an introduction to the format itself, see what a QR code is and how it works. This guide focuses on the question of exhaustion, duplicates, and the limits that actually matter.
Why QR codes are not a numbered resource
A QR code is a two-dimensional representation of data. A generator turns a message—often a URL—into a pattern of dark and light modules under specified encoding rules. A scanner decodes the pattern to recover the message.
QR patterns are not comparable to tickets that must each be issued with a new global serial number. DENSO WAVE makes the QR Code specifications available for standardized use and says no application is necessary to use a standards-compliant code. That supports the practical conclusion that creating an ordinary QR code does not consume a centrally allotted “QR number.” That conclusion follows from DENSO WAVE’s published standards and usage policy; it is not a count of codes issued by every possible service. Source: DENSO WAVE's QR Code FAQ.
If two people encode the same URL using the same encoder and settings, they may get the same pattern. That is not an allocation failure. They have simply encoded the same data.
How many possible QR codes are there?
There is no single honest number until we define what is being counted. For the common square QR Code Model 2, the DENSO WAVE version and capacity table covers Version 1 (21 × 21 modules) through Version 40 (177 × 177 modules). Version, encoding mode, and error-correction level all affect how much information fits.
| What is being counted? | Illustrative size | What the figure actually means |
|---|---|---|
| Every imaginable black-and-white arrangement on a 177 × 177 grid | About 10 to the power of 9,431 | Most arrangements are not valid QR codes. This is not a count of usable QR symbols. |
| An upper-bound estimate for standard QR symbol patterns across versions, correction levels, and masks | Less than roughly 10 to the power of 7,120 | A mathematical upper bound, not an exact enumeration of valid, decodable QR symbols. |
| Byte strings up to the maximum 2,953-byte payload of one Version 40-L symbol | Approximately 10 to the power of 7,111.5 (a 7,112-digit number) | A way to count potential message contents, not every possible QR appearance. |
| Identifiers in a hypothetical five-character system using 62 characters | 916,132,832 | A finite short-link namespace. This is an example, not a claim about OwnQR's production identifier length. |
Here is the important part: the first three rows describe different mathematical objects. An arbitrary grid can break the QR format. Multiple valid-looking patterns can represent the same message. And a hosted short link is just one possible kind of message carried by a QR symbol.
Where does the 2,953-byte figure come from?
DENSO WAVE lists 2,953 bytes as the maximum byte-mode capacity for Version 40 at error-correction level L. That is a maximum-capacity configuration—not a promise that every QR image can hold that much data. See DENSO WAVE's capacity table and published maximum-capacity summary.
A useful back-of-the-envelope count is:
256 to the power of 2,953 ≈ 10 to the power of 7,111.5
This counts the possible sequences of exactly 2,953 bytes. Including shorter sequences hardly changes the order of magnitude. The calculation does not, by itself, tell us the exact number of standards-compliant QR image patterns.
Level L prioritizes capacity. Other error-correction levels reserve more space for recovery information, reducing the amount of user data they can hold. DENSO WAVE explains the four correction levels.
Why isn't every arrangement of squares a valid code?
A QR symbol contains more than arbitrary dark and light pixels. It must respect its structural patterns, formatting information, and error-correction rules. Counting 2^31,329 possible black-and-white grids for a 177 × 177 square ignores all of those constraints.
That very large number describes possible grids, not possible working QR codes. The valid-symbol upper-bound estimate in the table uses available encoded-data codewords, eight mask choices, and version/error-correction combinations; it still overcounts because not every arbitrary codeword string represents a validly structured message. There is no need to present it as an exact total.
The mathematical limit depends on how information is encoded, not on a global count of QR code images. For the differences between numeric, alphanumeric and byte payloads, see QR code encoding modes. For the fixed patterns that occupy part of every symbol, see QR code anatomy. Neither topic implies that a unique QR code is consumed each time someone generates one.
Can two QR codes be the same—or lead to the same place?
Yes. Identical QR images are perfectly possible. When the same encoder receives the same content with the same selected settings, it can produce the same pattern each time. The pattern is not a one-time identity token. DENSO WAVE also notes that the same data may produce different patterns across encoder choices and settings in its QR Code FAQ.
Different QR images can also lead to the same page. Changing the selected version, correction level, or mask can change the pattern without changing the decoded URL. Adding a logo or using another generator can change the visible design again; that does not automatically change the stored destination.
To check these distinctions rather than rely only on theory, the OwnQR research workflow ran a documented software-only encoding and decoding experiment in November 2026. The encoder was the Nayuki implementation bundled with qrcode.react 3.2.0; the separate decoder was jsQR 1.4.0. It used synthetic example.com URLs—not real customer links—and did not involve printed codes or phone-camera tests.
| Software check | Observed result | What it does—and does not—establish |
|---|---|---|
| Encode the same content repeatedly using the same settings | The output pattern was identical in the tested runs | Confirms deterministic behavior in this implementation and setup. |
| Vary version, correction level, and mask for two fixed URLs | 2,448 parameter combinations yielded 2,448 different patterns | The same message can have many different appearances. |
| Decode those 2,448 patterns with jsQR 1.4.0 | 2,432 decoded as expected; 16 Version 23-L cases did not | This particular decoder had a reproducible version-table discrepancy; it does not show a problem in typical phone scanners. |
| Encode 200,000 distinct synthetic URL payloads | 200,000 distinct patterns, with no observed pattern collision | A limited implementation check, not a mathematical guarantee about every possible generator. |
The 16 decoder failures were localized to a Version 23-L alignment-pattern table discrepancy in jsQR 1.4.0. Correcting that table value in memory made the affected test cases decode. This detail matters because a failure in one decoder implementation should not be confused with the exhaustion of QR patterns, or treated as evidence that a printed code would fail on a phone.
Method note: The tests used a fixed random seed, recorded input parameters and outputs, and kept the source scripts. Results are specific to those library versions and simulated data. No customer QR codes, real-world scans, or print tests were used.
What can actually run out: hosted short codes and service availability
The practical limits are usually more ordinary than the headline question suggests.
A static URL QR can directly encode a full web address. A hosted redirect QR instead encodes a short address controlled by a service, which then sends the visitor to a destination. Both are QR patterns; the second adds a service dependency.
Consider a generic five-character short code using 62 possible characters (letters and digits). Its identifier space contains:
62^5 = 916,132,832 possible five-character strings.
That is a large but finite number, and a six-character namespace would have 62^6 = 56,800,235,584 possibilities. These examples describe hypothetical identifier systems. They are not OwnQR's confirmed production short-code length or capacity.
A service can generate candidate short codes, check whether a candidate is already in use, and retry if necessary. As a fixed namespace fills, repeated candidates become more likely and creation can become harder. That is a problem for the service's address-allocation system, not evidence that the underlying QR format has run out of patterns.
Availability matters separately. A QR image can still decode correctly even when the destination site has moved, a domain has expired, the linked page has been removed, or a redirect service is no longer operating. In other words, a decodable QR image and a reachable destination are different things.
For example, OwnQR's free static-image option encodes the supplied URL directly rather than sending scans through an OwnQR-hosted redirect. OwnQR-hosted features, by contrast, depend on OwnQR continuing to provide the service. This is a description of the product design, not a guarantee about how long a particular destination will remain available.
Are QR codes different from numbered retail barcodes?
Yes, in an important way. A retail U.P.C. barcode commonly carries a product identifier such as a GTIN. The identifier is assigned within a managed GS1 numbering system. A QR code is a format for encoding data; generating its pattern does not, by itself, allocate a new GS1 product identifier. GS1 US explains the difference between a U.P.C. barcode and a GTIN.
A QR code can itself contain a managed identifier, of course. In that case, the allocation rules belong to the identifier inside the code, not to every possible QR pattern.
How many years would it take to use up QR codes?
There is no defensible countdown. To calculate a date, we would need a meaningful definition of “used,” a pool whose members cannot be reused, and a rate at which that pool is being consumed. Ordinary QR encoding does not operate as such a worldwide allocation process.
For a particular hosted platform, you could instead model the remaining available short identifiers given its alphabet, code length, issuance rules, and actual occupancy. Those are platform-specific quantities, not a global expiration date for QR codes.
Frequently asked questions
Can two people create exactly the same QR code?
Yes. If they encode the same content with the same encoder and effective settings, the output can be identical. QR codes are not issued as globally exclusive serial numbers.
Can two different QR codes contain the same URL?
Yes. Different mask choices, sizes, correction settings, and visual treatments can produce different images that decode to the same URL. Our software test generated thousands of distinct patterns from two fixed example URLs.
What is the largest standard QR Code version?
For standard square QR Code Model 2, Version 40 is the largest version, with 177 × 177 modules. Under its maximum-capacity Version 40-L byte-mode configuration, it can hold up to 2,953 bytes. That is a symbol-grid and data-capacity limit, not a limit on how large you can print the image.
Can a QR code stop working even if it has not been damaged?
Yes. A code can still be readable while its linked website is unreachable or a hosted redirect no longer works. A scanner reading the pattern successfully does not guarantee that the online destination will respond.
Does a duplicate QR code mean a collision or security problem?
Not by itself. The same content is allowed to produce the same QR pattern. A hosted short-link system, however, must manage its own short identifiers so that one identifier does not accidentally point to conflicting destinations.
Could an old QR code be reused?
The same QR pattern can be generated again for the same data. Whether scanning an old physical code still reaches the intended destination depends on what was encoded and whether any associated website or redirect service remains available.
The takeaway
QR codes are not running out as a practical global resource. The mathematical space is immense, and repeating a pattern is not the same as spending a unique number. What users should check instead is what a QR encodes and who controls the destination.
If you want the fundamentals behind the pattern, begin with the QR code primer. For more on how correction settings trade capacity for resilience, see QR code error-correction levels.
Sources and research disclosure
- DENSO WAVE — Information capacity and versions: version sizes and capacity limits.
- DENSO WAVE — Error correction feature: why correction levels change capacity.
- DENSO WAVE — QR Code FAQ: use and standards policy.
- GS1 US — Barcode FAQs: UPC/GTIN distinction.
- OwnQR software research, November 2026: OwnQR retained the encoder/decoder test scripts, results JSON, calculations, and limitations for internal QA. Those research files are not linked for public download from this article. The tests used synthetic URLs, not real-world phone-camera scans or printing.
Editorial disclosure: This article was prepared with AI assistance using documented sources and software experiments. It has not received an independent human technical review. No camera or printed-code testing was performed.