2026-10-21 · 5 min read · Rahul Chitturi
- qr
- encoding
- debugging
The QR page draws one PNG data URL with margin 1 and width 320. The library default error correction is M. A box that trims to nothing clears the image and does not call the encoder. Any other character, including spaces around a short word, is part of the payload.
The encoder picks a mode. Digits use numeric mode. Uppercase letters and spaces use alphanumeric mode. Lowercase letters, a URL, and characters outside that set use byte mode. The mode decides how soon version 40 runs out of room.
Hit the limit for the mode you actually used
A string of 3391 uppercase A's encodes at version 40. One more A throws The amount of data is too big to be stored in a QR Code. A string of 2331 lowercase a's also reaches version 40, and the next a throws the same message. é is two UTF-8 bytes, so 1165 of them fit and 1166 do not. Four thousand zeros still encode, because digits are packed in numeric mode.
https://flashman.dev is byte mode, version 2, because of the lowercase letters and the punctuation. hi and the same letters with surrounding spaces produce different images. A newline is data too.
- Remove sample text before you measure a real payload.
- Expect lowercase to fill the symbol sooner than uppercase.
- Expect é to count as two bytes.
- Read the thrown sentence as a capacity error.
Keep the image and the text together
The download is flashman-qr.png. The image is a data URL that starts with data:image/png;base64,. There is no error-correction picker and no version picker. M and a quiet zone of one module are the settings the page always uses.
Use the QR tool for the symbol, the URL tool when the payload is an address you still need to encode, and the Base64 tool if you are inspecting the data URL itself. Shorten the text, or split it, when the error names the amount of data. A denser error-correction level is not available on this page.