Glossary
Kanji mode
Kanji mode packs Shift-JIS double-byte characters into 13 bits each instead of the 16 bits they would take in byte mode. It exists because QR codes were invented in Japan for Japanese text.
The saving
Shift-JIS encodes a kanji character in two bytes — 16 bits. Kanji mode compresses the valid Shift-JIS range into 13 bits, an 18% saving. Over a few hundred characters that is a whole version.
When it applies
Only to characters in the Shift-JIS double-byte ranges. Japanese text encoded as UTF-8 uses three bytes per character in byte mode — 24 bits — so kanji mode is nearly twice as efficient for Japanese content.
Chinese and Korean have no equivalent mode in the base standard; they go through byte mode as UTF-8.
Compatibility
Support is universal in Japan and good on modern phone cameras elsewhere. Because it requires the reader to interpret Shift-JIS, mixed-script content is usually safer in UTF-8 byte mode.
Related
- Encoding mode — Encoding mode is how characters are packed into bits. QR codes support numeric (3.33 bits/char), alphanumeric (5.5), byte (8) and kanji (13), and a single…
- ECI (Extended Channel Interpretation) — ECI is a mechanism for declaring which character set a QR code's byte data uses. Without it, byte mode has no declared encoding, and decoders simply guess…
- Data capacity — Data capacity is how much a QR code can hold, and it depends on three things at once: the version, the error-correction level and the encoding mode. The…