Text to hex converter
Convert text to hexadecimal bytes, or hex back to text.
Editor
Text to hex converter: what it does
Write a text as hexadecimal bytes, two digits per byte, or decode a hex dump back into text. Spaces, commas and prefixes such as 0x are accepted when decoding, so values copied from a debugger or a network capture work as they are.
Text to hex converter: how to use it
- Paste your text, or the hex bytes.
- Choose Text to hex or Hex to text.
- Select Apply and copy the result.
Text to hex converter: when to use it
- Inspect the bytes of a string that looks wrong because of an encoding problem.
- Decode a hex dump from a log, a packet capture or a debugger.
- Prepare a byte sequence for a script, a test fixture or a hardware tool.
Text to hex converter: examples
Input
Hi!
Result
48 69 21
Input
48 69 21
Result
Hi!
Input
48:65:6c:6c:6f 0x21
Result
Hello!
Text to hex converter: questions and answers
Which separators does decoding accept?
Spaces, commas, colons, hyphens and prefixes such as 0x or \x. The remaining digits must come in pairs.
Is the hex upper or lower case?
Encoding writes lower case; decoding accepts both.
Can I get the hex in upper case or without spaces?
Run Case converter on the result for upper case, or Remove extra spaces with “remove all spaces” for a continuous string.
Why does decoding give strange characters?
The bytes are not valid UTF-8 text, for example because they come from a binary file or another encoding.
Is my text sent to a server?
No. Everything runs in your browser on your own device, so your text never leaves it.
Related tools
Tools people often use together with this one.
- Text to binary converter
Convert text to binary code, or binary back to text.
- Base64 encode and decode
Convert text to Base64, or decode Base64 back to text.
- Unicode escape and unescape
Turn non-ASCII characters into \u escapes, or back.
- Morse code translator
Translate text to Morse code, or Morse back to text.
- ROT13 encoder and decoder
Scramble or unscramble letters with ROT13.
- URL encode and decode
Percent-encode text for a URL, or decode it back.