Hexadecimal text encoding represents each character of a UTF-8 string as one or more bytes, and each byte as exactly two hexadecimal digits, so a 5-letter ASCII word like Hello becomes the 10-character string 48656c6c6f. Converting hex back to text is the reverse of that step: split the input into byte pairs, treat each pair as a number from 0 to 255, and decode the resulting byte sequence with the UTF-8 standard. The Hex to Text Converter handles all three of the common notations (continuous pairs, ASCII-whitespace-separated groups, and exact 0xNN tokens) inside a single browser tab, rejects malformed input explicitly, and decodes the full byte array with fatal UTF-8 validation so damaged bytes never silently appear as the Unicode replacement character U+FFFD.

convert hex to text
Convert Hex to Text: Read Hex Strings as UTF-8 Bytes

What a Hexadecimal Text Encoding Looks Like

Hexadecimal, or hex, is a base-16 numbering system that uses the digits 0 through 9 and the letters A through F. One byte holds eight bits, so a byte can be written as exactly two hex digits: 00 through FF. When text is encoded as UTF-8, ASCII characters fit in one byte, common accented letters fit in two bytes, characters in most Asian scripts fit in three bytes, and supplementary characters such as emoji fit in four bytes. That means a single character can occupy one, two, three, or four pairs of hex digits in the source.

The simplest example is ASCII itself. The character H is code point U+0048, so it encodes as a single byte 0x48; the character e is U+0065, encoded as 0x65; the first l is U+006C, encoded as 0x6C; the second l repeats 0x6C; and o is U+006F, encoded as 0x6F. Concatenated, those five pairs form the continuous string 48656c6c6f, which a decoder must parse as exactly five bytes 48 65 6C 6C 6F and then interpret as UTF-8. The decoded characters are H, e, l, l, o, in that order.

Multibyte characters make the structure more interesting. The accented letter é is U+00E9, which UTF-8 encodes as the two-byte sequence C3 A9, so the hex source for that one character is C3A9, four digits rather than two. The supplementary emoji 😀 is U+1F600, encoded as four bytes F0 9F 98 80, which becomes the eight-digit string F09F9880. Recognizing that one character can span several hex pairs is essential when counting input length and matching it against the tool budgets described below.

Accepted Hex Formats and Which Option to Pick

Hexadecimal text comes from many sources, and the surrounding notation changes from one to another. A web API might return a continuous blob, a documentation example may include spaces for readability, and a C-style snippet may use the 0x prefix on every byte. The converter treats each style as a separate rule so the parser never has to guess.

NotationExample inputOptions to enable
Continuous pairs48656c6c6fASCII whitespace off, 0x prefixes off
Whitespace-separated48 65 6c 6c 6fASCII whitespace on, 0x prefixes off
Per-byte 0xNN tokens0x48 0x65 0x6C 0x6C 0x6FASCII whitespace on, 0x prefixes on
Mixed plain and 0x (invalid)0x41 42Always rejected

Plain mode requires every group to contain only the digits 0 through 9 and the letters A through F (uppercase or lowercase) and to have an even number of digits, so a group of 4869 is two bytes and a group of 48 is one byte when whitespace separation is enabled. Prefixed mode is more restrictive: if any case-insensitive 0x appears anywhere in the input, every whitespace-separated token must be exactly 0xNN, and plain tokens cannot appear in the same input. That strict separation keeps the parser from silently treating 0x41 42 as valid, because the second token lacks the prefix. For a deeper walkthrough of both notations, see the plain and 0xNN reference.

How to Convert Hex to Text

  1. Copy the hexadecimal bytes from the source. Continuous sources such as 48656c6c6f paste directly; spaced sources such as 48 65 6c 6c 6f need the ASCII-whitespace option enabled; per-byte sources such as 0x48 0x65 0x6C 0x6C 0x6F need the 0x prefix option enabled as well.
  2. Open the Hex to Text Converter and paste the input into the hex field. If the source contains a leading byte order mark such as EF BB BF, leave it in place; the tool consumes a leading BOM for you and decodes the rest as ordinary UTF-8.
  3. Toggle the syntax options so the permitted notation matches your input. Enabling whitespace while your source is continuous still works, but enabling 0x prefixes when the source contains no prefix is a no-op and may surprise you if the source turns out to be mixed.
  4. Run the decode. The tool checks the 2,000,000-character raw-input budget first, then validates the parsed byte count against the 1,000,000-byte output budget before allocating the byte array, and finally decodes the complete array with fatal UTF-8 validation.
  5. Read the decoded text in the read-only output field. The byte count is shown alongside the text so you can confirm that the source length divided by two (or by the larger per-byte overhead for prefixed input) matches the number of decoded bytes.
  6. Copy the decoded text with the copy button if your browser grants clipboard access in a secure context. The button is disabled only when the decoded text has no code units, and a failed permission still leaves the text selectable for a manual copy.

If the decode fails, the interface reports one specific reason rather than guessing. An odd-length digit group produces an odd-nibble error, a comma or other non-ASCII separator produces a mixed-syntax error, a standalone continuation byte or truncated multibyte sequence produces an invalid-byte error, and a budget overflow produces a budget error. Correct the indicated problem and re-run; the previous output, error, and copy state are cleared automatically on every edit.

Why Fatal UTF-8 Decoding Matters

A non-fatal decoder replaces every malformed byte with the Unicode replacement character U+FFFD, which lets corrupted input look like successful text and hides the very bytes you need to investigate. The Hex to Text Converter uses the browser TextDecoder with fatal: true, so any stray continuation byte, truncated multibyte sequence, overlong encoding, encoded surrogate, or value above U+10FFFF fails the entire decode and returns no partial output. Nothing is silently replaced, no earlier valid prefix is returned as success, and no bad suffix is dropped. The behaviour follows the MDN TextDecoder reference for the fatal option and the WHATWG Encoding Standard for the underlying UTF-8 state machine.

A few concrete cases show why this matters:

  • ASCII (48 65 6C 6C 6F) decodes to Hello, the most common baseline.
  • U+00E9 (C3 A9) decodes to é, the simplest two-byte case.
  • Two CJK characters such as E4 B8 AD E5 9B BD decode to 中国, the three-byte case.
  • A supplementary emoji such as F0 9F 98 80 decodes to 😀, the four-byte case.
  • A standalone continuation byte such as 80, an overlong form such as C0 AF, or an encoded surrogate such as ED A0 80 all fail with an explicit invalid-sequence error rather than returning U+FFFD.
  • A leading BOM (EF BB BF 41) decodes to A because the standard TextDecoder wrapper consumes a leading byte order mark; the same bytes in the middle of text (41 EF BB BF 41) decode as the visible character U+FEFF between two As and are not removed.

Those rules match the WHATWG Encoding Standard for the UTF-8 decoder and the constraints in RFC 3629, which independently defines the valid byte ranges and the U+10FFFF scalar ceiling. The tool does not guess Windows-1252, ISO-8859-1, UTF-16, Shift_JIS, or any other legacy encoding, because silent guessing can change byte meaning. If the source really is in one of those encodings, treat the conversion as a separate task and pre-convert the bytes to UTF-8 before passing them in.

Common Errors and How to Fix Them

Hex strings copied from documentation, terminal output, or API traces frequently include characters that look like separators but are not in the accepted set. The Hex to Text Converter rejects them with a clear reason so the fix is obvious from the message alone.

InputResultReason
4 8Odd nibble errorWhitespace does not repair an incomplete nibble
48,65,6C,6C,6FMixed syntax errorCommas are not in the accepted separator set
48-65-6C-6C-6FMixed syntax errorDashes are not accepted as separators
0x410x42Mixed syntax errorPrefixed tokens must be separated by enabled whitespace
0x041Invalid token errorPrefixed tokens must be exactly 0xNN, not three digits
41 80Invalid byte error0x80 is a standalone continuation byte with no leading byte
C0 AFInvalid byte errorOverlong encoding is forbidden by RFC 3629
ED A0 80Invalid byte errorUTF-16 surrogate halves cannot be encoded as UTF-8

For long inputs, the most common failures are budget overflows. Raw input may contain at most 2,000,000 UTF-16 code units, parsed output may contain at most 1,000,000 bytes, and decoded text may contain at most 1,000,000 UTF-16 code units. Prefixed notation uses more source characters per byte than continuous notation, so it can hit the raw-input budget before the byte budget; that ordering is expected and reported explicitly. Split the source into smaller chunks and decode each one separately if you need to exceed those limits, or extract just the byte column of a memory dump before decoding.

When to Use a Different Tool

Hexadecimal is one of several ways to transport non-text bytes through text-only channels, and the right decoder depends on the source. For binary rather than hexadecimal input, use Binary to Text, which accepts 8-bit groups or 8-bit binary strings and decodes them with the same fatal UTF-8 rules. For Base64 transport data, use Base64 Encode and Decode, which treats Base64 as RFC 4648 transport and produces strict UTF-8 output. For UTF-16 byte streams, Windows-1252 files, or other legacy encodings, decode the source into hexadecimal first with a trusted workflow and only then pass the resulting hex bytes to the Hex to Text Converter.

For formatted memory dumps with addresses and ASCII columns, the byte column has to be extracted before the converter sees it. For encryption, hashing, signing, or any task that needs a key, the hex-to-text step is at best a small piece of a larger process; for a complete round trip with authenticated encryption, see the AES tool, and for digest verification, see the SHA-256 and CRC-32 calculators. Hex decoding is intentionally narrow: it parses bytes and decodes UTF-8, nothing more. It does not interpret integer literals, reverse byte order, remove nulls, evaluate escapes, or execute decoded text.

All parsing, byte allocation, fatal UTF-8 decoding, display, and clipboard preparation happen locally in the current tab. No source bytes, decoded characters, or clipboard content leave the browser, so converting hex to text with this tool is safe to run on internal logs, captured API responses, and other bytes that should not be uploaded to a remote service.