05 // Unicode, Symbol & Encoding WorkbenchUTF8-HEX-INSPECTOR
Grapheme, Code Point & UTF-8 Byte Length Counter
Accurately measures UTF-8 payload byte size (for S3 keys, VARCHAR byte limits, SMS segments, and HTTP headers) alongside UTF-16 code units and Unicode code points.
UTF-8 BYTES
27
CODE POINTS
20
UTF-16 UNITS
20
BYTES / CHAR
1.35
| # | Char | Code Point | Decimal | UTF-8 Hex | UTF-16 |
|---|---|---|---|---|---|
| 1 | H | U+0048 | 72 | 48 | 0048 |
| 2 | e | U+0065 | 101 | 65 | 0065 |
| 3 | l | U+006C | 108 | 6C | 006C |
| 4 | l | U+006C | 108 | 6C | 006C |
| 5 | o | U+006F | 111 | 6F | 006F |
| 6 | ␣ | U+0020 | 32 | 20 | 0020 |
| 7 | 世 | U+4E16 | 19990 | E4 B8 96 | 4E16 |
| 8 | 界 | U+754C | 30028 | E7 95 8C | 754C |
| 9 | ␣ | U+0020 | 32 | 20 | 0020 |
| 10 | — | U+2014 | 8212 | E2 80 94 | 2014 |
| 11 | ␣ | U+0020 | 32 | 20 | 0020 |
| 12 | Δ | U+0394 | 916 | CE 94 | 0394 |
| 13 | x | U+0078 | 120 | 78 | 0078 |
| 14 | ␣ | U+0020 | 32 | 20 | 0020 |
| 15 | = | U+003D | 61 | 3D | 003D |
| 16 | ␣ | U+0020 | 32 | 20 | 0020 |
| 17 | 0 | U+0030 | 48 | 30 | 0030 |
| 18 | . | U+002E | 46 | 2E | 002E |
| 19 | 0 | U+0030 | 48 | 30 | 0030 |
| 20 | 5 | U+0035 | 53 | 35 | 0035 |
Was this tool helpful?
Reference Table
- 01PostgreSQL `VARCHAR(n)` counts Unicode characters, whereas Oracle `VARCHAR2(n BYTE)` and network packet headers enforce raw UTF-8 byte counts.
- 02Standard GSM-7 SMS messages fit 160 characters, but a single non-GSM Unicode glyph switches encoding to UCS-2 (70 UTF-16 code units per segment).
Frequently Asked Questions
How do I count exact UTF-8 bytes in modern JavaScript?+
Run `new TextEncoder().encode(str).length` — available natively in all modern browsers, Node.js, Deno, and Edge runtimes.
How do I count visible user-perceived characters (graphemes)?+
Use `Array.from(new Intl.Segmenter('en', { granularity: 'grapheme' }).segment(str)).length` so ZWJ emoji sequences count as 1 character.
How many UTF-8 bytes do CJK (Chinese/Japanese/Korean) characters take?+
Almost all common CJK Unified Ideographs (`U+4E00–U+9FFF`) occupy 3 bytes per character in UTF-8 and 2 bytes in UTF-16.