Unicode Encoder

Encode text to Unicode escape sequences (like \u0041 for "A"). This tool helps you convert regular text into Unicode escape sequences. Useful for programming, internationalization, and character encoding tasks.

When to use this tool

You need to store special characters in escaped form.

You want to debug encoding issues in JSON or source files.

Examples

Encode emoji

Input

Hello 👋

Output

Hello 👋

Surrogate pairs are used for emoji in \uXXXX format.

Developer use cases

Convert emoji to escaped sequences for config files.

Prepare strings for systems that require \uXXXX escapes.

Common mistakes to avoid

Assuming \uXXXX works for all characters (some need \UXXXXXXXX).

Double-escaping strings when pasting into JSON.

Format and behavior notes

Uses \uXXXX for BMP characters and surrogate pairs for others.

Useful for JSON or source code escaping.

Frequently Asked Questions

How do I encode text to Unicode?

Paste your text into the input field and the Unicode escape sequences will appear automatically in the output.

What format are Unicode escape sequences?

Unicode escape sequences use the format \uXXXX where XXXX is the hexadecimal Unicode code point (e.g., \u0041 for "A").

Which characters are encoded?

All characters are encoded as Unicode escape sequences, including ASCII characters. For example, "A" becomes \u0041 and "Hello" becomes \u0048\u0065\u006C\u006C\u006F.