Builds a QR code from text, a URL, Wi-Fi credentials, an email address or a phone number.
All of the encoding happens inside this page.
It also shows the version, the mask pattern and the codeword breakdown of the finished code,
so you can see what actually happened in there.
Nothing you type is ever sent anywhere.
There is no QR library loaded from anywhere else either — the encoder is written directly
into this page. Once the page has loaded you can go offline and it still works.
That is why it is fine to type in your Wi-Fi password.
Build
Scanning this connects the device to the network. It is meant for the printed
card you leave out for guests. The password you type here is not sent anywhere either.
Scanning this opens the dialler (on most devices it does not place the call by itself).
The result
What happened in there
How the mask pattern gets chosen
To keep the dark and light modules from clumping, a QR encoder tries all eight
“masks” and keeps the one with the lowest penalty score.
Below are the eight scores for the code above.
How this tool is built
No library is used
The procedure in JIS X 0510 / ISO 18004 (pick a mode → turn it into a bit string →
add Reed-Solomon error correction codewords → interleave the blocks → place the
function patterns for that version → score all eight masks) is written out inside this page.
Not one external script is loaded, so no network request happens.
The mode is picked from what you type
Digits only gets numeric mode (three characters in ten bits); uppercase letters and a few
symbols get alphanumeric mode (two characters in eleven bits); anything else gets byte mode
(UTF-8, eight bits per byte). The same message written with digits only produces a smaller code.
Spare capacity is spent on error correction
When the error correction level can be raised without changing the version (the size), it is
raised by default. If the code is the same size either way, the one that survives smudges and
faint printing is the better deal. You can turn this off above.
Things worth saying plainly
Kanji mode is not supported. QR codes have a kanji mode that packs Japanese
efficiently (thirteen bits per character in Shift_JIS), but the conversion table it needs is
large, so it is not included here. Japanese goes in through UTF-8 byte mode instead
(three bytes, twenty-four bits, per character).
Long Japanese text therefore produces a larger code than it strictly has to.
Micro QR is not supported. Only ordinary QR codes, versions 1 to 40.
There is no logo-in-the-middle feature.
Covering the centre can lower the scan rate, and there is no way to measure how much it lowers
it from inside this page.
The masks are scored before the format information is written in.
Implementations read this part of the standard (7.8.3) differently, and some score the masks
with the format information already in place. Either reading produces a scannable code, but the
mask number that wins can differ. This tool scores without the format information present.
Always scan the finished code with a real device before you use it.
Printing is where it goes wrong: too small, too little quiet zone, or too little contrast and
it will not read. Keep at least four modules of quiet zone, and the closer the two colours are
to black and white the safer you are.
About QR codes in general
A QR code does not show you where it leads. Do not scan a code stuck up in a
place you do not know and then open whatever URL comes out — codes get pasted over as a
scam, and it does happen.
A shortened URL makes the code smaller, but it hides the destination even further. For the
people you are handing it to, the plain URL is the kinder choice.
The codes this page builds are static: the destination cannot be changed after
the fact. Read the other way round, that means
nobody else can swap the destination later either
(a “dynamic QR” whose target can be changed goes through a vendor's server).