QR Code Generator
A free QR code generator for any text or link, made in your browser. Nothing is uploaded, nothing is shortened, and the code does not expire.
QR code
- Version
- 2 (25 x 25 modules)
- Error correction
- M - Medium, recovers about 15%
- Payload
- 24 of about 26 bytes used
- Mask The lowest penalty of the eight mask patterns, which scored 587, 659, 425, 544, 528, 592, 514, 688.
- 2 of 0-7, penalty 425
How the QR Code Generator works
A QR code is your data plus the arithmetic that lets a camera recover it from a bad photograph. There are four steps.
First the text becomes bits. This encoder uses byte mode, which takes the UTF-8 bytes of whatever you type, so it handles any language and any emoji at a cost of one to four bytes per character. The spec also defines a numeric mode and an alphanumeric mode that pack digits and uppercase letters more densely, which is why a code holding only numbers can be smaller than one holding the same count of mixed characters.
Then comes the error correction, which is most of what a QR code is. Reed-Solomon parity codewords are computed over GF(256) and appended to the data. GF(256) is a finite field with 256 elements where multiplication is addition of logarithms. At level L about 7% of the symbol can be destroyed and still recovered; at level H about 30% can. That is the whole reason you can print a logo over the middle of a QR code and have it still scan, and it is why the levels cost capacity: at level H a version 1 symbol holds 7 bytes where at level L it holds 17.
The data and parity are then split into blocks and interleaved before being laid into the grid. If a block's codewords sat together in the image, a coffee ring over that area would destroy one block completely and Reed-Solomon can only fix a bounded number of errors per block. Interleaved, the same ring damages every block a little, and every block stays inside its recovery budget.
Finally the grid is masked. Large blank areas and accidental finder-like patterns confuse a scanner, so the spec defines eight mask patterns, requires the encoder to score all eight against four penalty rules, and requires it to pick the lowest. The rules penalize runs of five or more, blocks of 2x2, patterns that look like a finder, and deviation from half-dark.
The quiet zone, four modules of blank space on every side, is part of the specification; codes printed hard against a border are the most common scanning failure.
QR Code Generator FAQ
Does this QR code expire?
No, and it cannot. The code contains your text directly. Nothing sits between the code and what it points at, so there is nothing that could be switched off. Codes from services that shorten the link first do expire, because what is actually encoded is a reference to a row in somebody's database.
Is my text sent anywhere?
No. The code is made in your own browser. There is no analytics on the content of the field and no request is made when you type.
Which error correction level should I use?
M unless you have a reason. L gives the smallest code and about 7% recovery and is fine for a screen; M recovers about 15% and is the common default; Q and H recover about 25% and 30% and are worth it for something printed small, printed on a curved surface, or with a logo over the middle. Higher levels need more modules for the same text, so the code gets denser.
Why did the code get bigger when I added a few characters?
Because versions are discrete. A symbol is 21, 25, 29 ... modules square, and when the payload crosses what the current version holds, the encoder has to step up to the next one, which adds four modules in each direction at once.
Can I put a logo in the middle?
Yes, and the error correction is what makes it work: at level H roughly 30% of the symbol can be obscured and still recovered. Keep the logo central, keep it under about a fifth of the area, and never cover the three corner finder patterns or the timing lines between them. Those are how the scanner locates and orients the code, and no amount of parity recovers them.
Will the same text always give the same code?
Yes. The encoding, the parity and the mask choice are all determined by the specification, and the mask is picked by scoring all eight against fixed penalty rules rather than by preference. Two correct encoders given the same text and level produce identical images.
How small can I print it?
About 2 cm across for a phone held at arm's length, and larger if the version is high, since more modules in the same space means each one is smaller. The practical limit is that a module should be at least four or five camera pixels. Always keep the four-module quiet zone.
Common QR payloads
- URL QR Code Generator
- WiFi QR Code Generator
- QR Code for an Email Address
- QR Code for a Phone Number
- QR Code for Text
- vCard QR Code Generator