Skip to content
Changelog
new tooladvanced & local

UTF-8 Visualizer

v1.0

The UTF-8 Visualizer shows how text is actually stored. Type or paste any text and each visible character is split three ways: the code points it's made of, the UTF-16 code units JavaScript uses, and the UTF-8 bytes a file would contain.

A character isn't always one thing. Click any chip in the grid and, if it's built from several code points (a combining accent, an emoji joined with zero-width joiners, a flag made of two regional indicators), the detail panel lists each code point with its U+XXXX notation, UTF-16 units and UTF-8 bytes, with leading and continuation bytes in different colors. "Show bit layout" expands a code point's bytes into a bit grid where the fixed template bits (110, 10, 1110 and so on) are dim and the bits that carry the character's value are highlighted.

Seven quick-pick samples cover the interesting cases: café with a single é versus "e" plus a combining accent (same text, different code-point count), 你好, the Spain flag, a four-person family emoji made of seven code points, and a bare combining-accent sequence. A totals bar shows characters, code points, UTF-8 bytes and UTF-16 code units, which rarely match once anything outside ASCII is involved.

If you paste a lone UTF-16 surrogate with no partner, the character is marked "invalid" and the detail panel explains it has no valid UTF-8 encoding, so it's shown as U+FFFD, the replacement character. Your text is remembered on this device, and Share puts it in a link.

All changes