Ethereum calldata, logs, and storage use hex (base-16) strings. The Hex ↔ Text converter decodes hex to UTF-8 text and encodes text to hex so you can read log or calldata strings and encode strings for contract input—fast, client-side, with no data sent to any server.
What is hex encoding in Ethereum?
Hex encoding represents binary data as hexadecimal (base-16) strings. Ethereum uses hex for calldata, logs, and storage. The Hex ↔ Text tool decodes hex (with or without 0x prefix) to UTF-8 text when valid, and encodes text to hex for contract calls or debugging. All conversions are performed in your browser; no data is sent to any server. Use it to decode Ethereum log data or calldata to readable text, or to encode strings for contract input. If hex-to-text shows replacement characters, invalid UTF-8 byte sequences are being replaced—ensure the hex is complete and represents valid UTF-8; odd-length hex may be handled as padded or invalid.
Key Features
- Hex in Ethereum — Hex is used for calldata, logs, and storage. This tool converts between hex and UTF-8 text.
- Hex to text — Paste hex (with or without 0x). Tool decodes to UTF-8 text if valid.
- Text to hex — Enter text; tool encodes to hex for contract calls or debugging.
- Privacy — All conversions are performed in your browser. No data is sent to any server.
- When to use — Decode log/calldata to readable text, or encode strings for contract input.
- Replacement characters — Invalid UTF-8 is replaced. Ensure hex is complete and valid UTF-8; odd-length hex may be padded or invalid.
How to Use the Hex ↔ Text Converter
- Open the Hex ↔ Text tool.
- To decode: paste hex string (with or without 0x). To encode: enter text. Copy the result.
- Use the "Use tool" button on the docs page if you are reading this from the documentation.
Real Use Cases
Why Use the Hex ↔ Text Converter Instead of Alternatives?
- vs. Keccak256 Hasher — Keccak256 Hasher hashes data. This tool converts hex ↔ text. Use hasher for hashing; use this for string decode/encode.
- vs. Hex-Decimal Converter — Hex-Decimal Converter converts hex to decimal numbers. This tool converts hex to UTF-8 text. Use decimal for numbers; use this for strings.
- vs. ABI Encoder & Decoder — ABI Encoder & Decoder handles ABI types and packing. This tool is raw hex ↔ text. Use ABI for full calldata; use this for simple string hex.
- vs. Manual — No need to parse hex by hand. Paste or type, get text or hex.
Benefits for EVM Developers
- Developers — Decode log and calldata strings. Encode strings for contract input. One place for hex ↔ text.
Common Mistakes
- Replacement characters — Invalid UTF-8 byte sequences are replaced. Ensure the hex is complete and represents valid UTF-8. Odd-length hex may be handled as padded or invalid.
- Expecting ABI decode — This tool is raw hex ↔ text. For typed parameters use ABI Encoder & Decoder.
- Wrong encoding — Tool uses UTF-8. Other encodings (e.g. Latin-1) will differ. Match contract encoding.
- Forgetting to copy — Copy the result before closing the tab.
Frequently Asked Questions
What is hex encoding in Ethereum?
Hex encoding represents binary data as hexadecimal (base-16) strings. Ethereum uses hex for calldata, logs, and storage.
How do I convert hex to text?
Paste your hex string (with or without 0x prefix) and the tool will decode it to UTF-8 text, if valid.
Can I encode text to hex?
Yes. Enter your text and the tool will encode it to a hex string, suitable for contract calls or debugging.
Is my data processed securely?
Yes. All conversions are performed in your browser. No data is sent to any server.
When should I use the hex–text converter?
Use it to decode Ethereum log data or calldata to readable text, or to encode strings for contract input.
Why does hex to text show replacement characters?
Invalid UTF-8 byte sequences are replaced. Ensure the hex is complete and represents valid UTF-8. Odd-length hex may be handled as padded or invalid.
Hex ↔ Text gives you hex decode/encode in one place: paste hex or text, get text or hex. No server, no account. For numbers use Hex-Decimal Converter, for hashing use Keccak256 Hasher, and for calldata use ABI Encoder & Decoder.
Use the Hex ↔ Text tool to convert between hex and UTF-8 text.