🔢 Text to Hex Converter
Convert text to hexadecimal and vice versa. Each character becomes its hex code point.
About the Text to Hex Converter
This converter runs entirely in your browser. Use To Hex to turn any text into its hexadecimal code points, and From Hex to convert the hex back into readable text. Nothing is uploaded — conversion happens locally with JavaScript.
How it works
- To Hex — Each character is converted to its Unicode code point, then written as a 2+ digit hex value.
- From Hex — Hex pairs are parsed back into code points and rendered as characters.
- Formats — Choose between space-separated (
48 65 6c 6c 6f), no spaces (48656c6c6f), or 0x-prefixed (0x48 0x65 0x6c 0x6c 0x6f).
Common use cases
- Inspecting the raw byte values of a string for debugging.
- Encoding non-printable or special characters for transport.
- Learning how characters map to code points in Unicode.
- Preparing data for systems that expect hex-encoded input.
Frequently asked questions
Does this tool upload my text? No. All conversion happens locally in your browser. Your content never leaves your device.
How are non-ASCII characters handled? Each character's full Unicode code point is converted. Characters above U+FFFF produce 4+ digit hex values.
Why do some characters become more than two hex digits? Because the conversion uses Unicode code points, not raw bytes. Characters like emoji and CJK characters have code points larger than 255, so they need more than two hex digits.
Is there a length limit? The only limit is your browser's available memory. Even very long strings convert quickly.