UTF-8 Viewer

Expand text into its UTF-8 byte sequence; see each character's decimal / hex / binary

Chars: {{ charCount }} Bytes: {{ byteCount }}
#CharDecimalHexBinary
{{ r.index }} {{ r.display }} {{ r.dec }} {{ r.hex }} {{ r.bin }}
Showing first {{ maxRows }} bytes, {{ rows.length }} bytes total
Enter text to see the UTF-8 byte sequence here
Hex Tool →

About UTF-8 Encoding

UTF-8 is a variable-length Unicode encoding: ASCII characters (0-127) take 1 byte; common non-ASCII characters take 3 bytes; some rare characters and emoji take 4 bytes. It is the most popular character encoding on the internet, and the underlying encoding this site uses for all text.

With this tool you can see directly that "€" is encoded as three bytes E2 82 AC (decimal 226, 130, 172), which explains why the same non-ASCII character takes different sizes under different encodings.

Examples

Input: → Bytes: E2 82 AC (3 bytes)

Input: A → Bytes: 41 (1 byte, i.e. ASCII 65)

FAQ

Q: Why does one non-ASCII character show 3 bytes?
A: In UTF-8, characters in the U+0800 to U+FFFF range (covering most Chinese characters) use a fixed 3-byte encoding. This is by the UTF-8 variable-length rule, not an error.
Q: How do hex, decimal and binary correspond?
A: All three describe the same byte value in different bases. For example byte value 228 is E4 in hex and 11100100 in binary. This tool lists them side by side for easy comparison.