TextArray
100% local

Hex to text and back

Convert text to hexadecimal and hex back to text, byte for byte in UTF-8.

Input
Output

Hex to text and back

Hexadecimal is how bytes are written when humans need to read them: two digits per byte, 00 through ff. Paste text to see the exact UTF-8 bytes behind it, or paste a hex dump from a log, a packet capture or a debugger and read the message back out. The mode selector switches direction, and the result updates as you type.

The separator option decides the shape of the output. Space-separated pairs are the classic dump format and the easiest to scan by eye. Unseparated hex is what checksums, colour values and database blob columns look like. The 0x prefix suits C, Go and Rust byte literals; the \x prefix matches Python bytes objects and shell escapes. Uppercase digits are there for the many formats that expect A-F rather than a-f.

Reading hex back is deliberately tolerant, because real hex arrives messy. Spaces, tabs and line breaks are ignored, 0x and \x prefixes are stripped wherever they appear, and upper and lower case mix freely — so a copy-paste out of a stack trace usually just works. Two things are reported instead of guessed at: an odd number of digits, which means a digit went missing, and characters outside 0-9 a-f. Bytes that are not valid UTF-8 decode to the replacement character, so you can still see where a sequence broke.

Everything runs in your browser using its built-in UTF-8 encoder. Nothing is uploaded, which matters when the hex you are inspecting came from a payload, a token or a private file. The tally under the output shows characters against bytes, so multi-byte characters are easy to spot: an emoji costs four bytes, an accented letter two.

FAQ

Why is my hex longer than my text?
Every byte takes two hex digits, and text is encoded as UTF-8 — where ASCII is one byte per character, accented letters take two and emoji take four. A 5-character word can easily be 8 bytes and 16 digits.
Which hex formats can it read?
All the ones it writes, and most others: spaced pairs, unbroken strings, 0x-prefixed and \x-prefixed bytes, upper or lower case, spread across as many lines as you like. Whitespace and prefixes are stripped before decoding.
Why do I get an odd-number-of-digits error?
A byte is always two digits, so an odd count means one was lost, usually to a truncated copy. Check the start and end of the string. Commas and other punctuation are not accepted as separators — remove them, or space the bytes out.
What are the black diamond characters in the decoded text?
That is U+FFFD, shown wherever the bytes are not valid UTF-8 — typically because the hex came from binary data or from text in another encoding, such as Windows-1250.
Is my text uploaded anywhere?
No. The conversion runs entirely in your browser and your text never leaves your device.