Hex Encoder / Decoder
Convert text to and from hexadecimal — with separators, prefixes, a hex dump view and file support.
What this tool does
Text converts to hexadecimal and back in either direction, with full control over exactly how the hex is formatted — and it is not limited to typed text: a file dropped in is read as raw bytes, so its actual binary content can be inspected as hex, not just a text string.
Working with any file, not only typed text
Opening a file reads its bytes directly rather than trying to interpret it as text first, so an image, an executable, or any other binary file can be inspected the same way a plain string would be. Decoding hex back the other way can produce a real downloadable binary file too, not only decoded text — a full round trip from bytes to hex and back to bytes.
The xxd-style hex dump
Turning on the dump view lays the bytes out the way the classic
Unix xxd/hexdump -C tools do: a
hexadecimal offset, sixteen bytes per row grouped into two columns
of eight, and the same bytes shown again as printable ASCII (or a
dot for anything that is not) on the right — the standard format
for actually reading what is inside a file, not just a raw hex
string with no structure.
Formatting hex for wherever it is going
Plain hex means different things in different contexts, so the
separator (space, comma, colon, dash, or none), an optional
0x or \x prefix per byte, letter case,
and how many bytes appear per line are all independently
controlled — matching whatever a byte array literal in source code,
a config file, or a log format actually expects, rather than one
fixed style. Decoding is lenient about all of this too: prefixes
and any stray non-hex characters in pasted input are stripped
automatically before the hex is read.
Privacy
Encoding, decoding, and reading a file all happen in your browser. Nothing you paste, drop, or load is sent to a server.