# Hex/Unicode Converter

Convert characters to/from hex (\xXX) and Unicode (\uXXXX) escape sequences

> Canonical page: https://elysiatools.com/en/tools/hex-unicode-converter

- **Category:** Format Conversion

- **Keywords:** hex, unicode, escape, encode, decode, character, string, hex converter, unicode converter

## Overview

The Hex/Unicode Converter is a utility tool that converts text characters to and from hexadecimal (\xXX) and Unicode (\uXXXX) escape sequences. It supports encoding and decoding for programming, data serialization, and text processing tasks.

## Inputs

- **Input Text** (textarea): Enter text to convert...
- **Operation** (select)
- **Output Format** (select)

## When to use

- When you need to encode text into hex or Unicode escapes for use in code or configuration files.
- When you have escaped sequences in logs or data and want to decode them back to readable text.
- When working with international characters and require conversion between different escape formats for compatibility.

## How it works

- Enter or paste your text into the input textarea.
- Select the desired operation: convert to hex, from hex, to Unicode, or from Unicode.
- Choose the output format: with prefix, compact, or array.
- The tool processes the input and displays the converted text instantly.

## Use cases

- Debugging escaped strings in source code or log files to quickly identify issues.
- Preparing text data for APIs or systems that require specific escape sequences for proper parsing.
- Converting international text to portable escape formats for cross-platform data exchange.

## Frequently asked questions

### What is the difference between hex and Unicode escapes?

Hex escapes (\xXX) use two-digit hexadecimal codes for characters, while Unicode escapes (\uXXXX) use four-digit codes to support a broader range of characters.

### Can I convert multiple characters at once?

Yes, the tool processes the entire input text, converting all characters according to the selected operation.

### What output formats are available?

You can choose prefix format (e.g., \x41), compact format (e.g., 41), or array format for listing multiple values.

### Is there a limit on input length?

The tool handles standard text inputs efficiently, but very large texts may impact performance; it's designed for typical use cases.

### How do I use the array format?

Array format outputs the converted values as a list, which is useful in programming contexts where you need an array of character codes.

## Related tools

- [ASCII85 Converter](https://elysiatools.com/en/tools/ascii85-converter): Encode and decode text to/from ASCII85 format (Adobe version)
- [Base32 Converter](https://elysiatools.com/en/tools/base32-converter): Encode and decode text to/from Base32 format with multiple variants
- [Base45 Converter](https://elysiatools.com/en/tools/base45-converter): Encode and decode text to/from Base45 format (RFC 9285)
- [Base58 Converter](https://elysiatools.com/en/tools/base58-converter): Encode and decode text to/from Base58 format with Bitcoin and Ripple variants
- [Base62 Converter](https://elysiatools.com/en/tools/base62-converter): Encode and decode text to/from Base62 format (0-9, A-Z, a-z)
- [Base64 Converter](https://elysiatools.com/en/tools/base64-converter): Encode and decode data to/from Base64 format with URL-safe options
- [Base91 Converter](https://elysiatools.com/en/tools/base91-converter): Encode and decode text to/from Base91 format (ascii+basE91 algorithm)
- [Braille Converter](https://elysiatools.com/en/tools/braille-converter): Convert text to Braille Unicode characters or decode Braille to text

## Samples

- [Hex/Unicode Encoding Format Samples](https://elysiatools.com/en/samples/text-hex-unicode-formats): Examples of hex (\xXX) and unicode (\uXXXX) escape sequence encoding formats
- [Copyright-Free MP3 Audio Samples](https://elysiatools.com/en/samples/mp3-samples): Collection of royalty-free audio samples for testing and development purposes including nature sounds, meditation music, and ambient audio
- [Web Image Processing Python Samples](https://elysiatools.com/en/samples/web-image-processing-python): Web Python image processing examples using PIL/Pillow including reading, saving, resizing, and format conversion
- [Special Characters Samples](https://elysiatools.com/en/samples/text-special-characters-samples): Sample text files with various special characters, punctuation, and symbols for testing non-alphanumeric character removal

## Related content

- [Unicode, Emoji, and Invisible Character Debugging](https://elysiatools.com/en/hubs/unicode-emoji-debugging): Find hidden or confusable Unicode characters, inspect emoji and domain representations, normalize only when justified, and verify the cleaned copy before it reaches search, URLs, forms, or parsers.
- [Binary Payload Encoding, Serialization, and Round-Trip Verification](https://elysiatools.com/en/hubs/binary-payload-serialization): Convert structured data between binary serialization formats, text transport encodings, and escaped representations, then verify fields and bytes through a controlled round trip.
