# 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 code can switch modes mid-stream to use the cheapest one for each run.

Source: https://useqr.app/glossary/encoding-mode · Last reviewed 2026-08-21 · UseQR is free forever, MIT licensed, no signup.

---

## The four modes

| Mode | Bits per char | Character set |
|---|---|---|
| Numeric | 3.33 | `0-9` |
| Alphanumeric | 5.5 | `0-9`, `A-Z`, space, `$ % * + - . / :` |
| Byte | 8 | any, UTF-8 in practice |
| Kanji | 13 | Shift-JIS double-byte |

Note what alphanumeric mode does **not** include: lowercase letters, `?`, `=`, `&`, `#`,
`_`, `~`. A single lowercase letter or query separator forces the whole segment into byte
mode.

## Mode switching

A good encoder segments the input and switches modes to minimise total bits, paying a small
mode-indicator and character-count cost per switch. A serial number like `ABC-123456789012`
is cheaper as an alphanumeric run than as bytes.

## The practical lesson

If you control the payload — a serial number, a coupon token, a short URL — restricting it
to digits and uppercase makes the code materially smaller for free.
