Hex to Text Converter
The hex bytes 48 65 6c 6c 6f decode to the word Hello. This hex to text converter translates hexadecimal byte strings into readable text and back again. It accepts hex with or without spaces, commas, or 0x prefixes, handles both cases, and decodes full UTF-8, so accented characters and symbols survive the round trip.
Quick answer
Computers store text as bytes, and hex is a compact way to write those bytes, two hex digits per byte.
Output
Hello
Bytes
5
What this tells you
- •Computers store text as bytes, and hex is a compact way to write those bytes, two hex digits per byte.
- •The letter H is byte 72 in decimal, which is 48 in hex.
- •Decoding reads each hex pair, converts it to a byte, and interprets the bytes as UTF-8 text.
- •Encoding runs the same steps backward, text to bytes to hex pairs.
How to Use
- 1Pick a direction, hex to text or text to hex.
- 2Paste your input. Hex can include spaces, commas, or 0x prefixes, which are stripped automatically.
- 3Read the converted output and the byte count.
- 4If hex refuses to decode, check for an odd digit count or bytes that are not valid UTF-8.
How It Works
Formula
each byte = two hex digits, text = UTF-8(bytes)Hexadecimal is base 16, using 0-9 and a-f, and one byte (0-255) always fits in exactly two hex digits. The pair 48 means 4 x 16 + 8 = 72, which is the UTF-8 code for H. A hex string decodes by splitting into pairs, converting each to a byte, and reading the byte sequence as UTF-8, the encoding behind almost all modern text.
Calculation note: values are processed in the order shown above, using the current input units.
Worked Examples
Decode a classic
Five bytes, one per letter: 48=H, 65=e, 6c=l, 6c=l, 6f=o.
Encode a word
c is 0x63, a is 0x61, t is 0x74.
Decode with 0x prefixes
Prefixes and spacing are cleaned up before decoding.
Common Characters in Hex
UTF-8 byte values for everyday characters.
| Character | Hex | Decimal |
|---|---|---|
| A | 41 | 65 |
| a | 61 | 97 |
| 0 | 30 | 48 |
| space | 20 | 32 |
| ! | 21 | 33 |
| ~ | 7e | 126 |
Common mistakes
- Pasting an odd number of hex digits. Bytes need two digits each, so a lone trailing digit means something got cut off.
- Confusing hex text encoding with hex numbers. 48 as a hex number is 72, but as an encoded byte it is the letter H.
- Expecting arbitrary bytes to decode. Random hex often is not valid UTF-8 text, and the converter reports it rather than guessing.