TOOLTIKI Lovable tool, really free
Developer Encoding

Unicode escape converter

What you would call characters
12
Code points
12
UTF-16 code units
12
UTF-8 bytes
16

Inspected in your browser · nothing is uploaded

Local · decodes and encodes at the same time
Advertisement
320 × 100

Escapes every non-ASCII character into JavaScript, HTML, CSS or URL notation, and decodes escapes back into characters. The unescaped box always shows what your input decodes to, so it works in both directions at once.

How to use the unicode escape converter

1 Paste text with accents or symbols.
2 Pick the escape style your language uses.
3 Copy the escaped version — or paste escapes in to decode them.

You need this when something in the chain cannot carry the character itself. A properties file that must be plain ASCII, a legacy system that mangles anything above 127, a CSS content value, a URL query string. Escaping keeps the meaning while making the bytes safe.

The four styles are genuinely different, not just cosmetic. JavaScript uses \u00E9, and above U+FFFF must use the brace form \u{1F600}. HTML uses é or é, and either is fine. CSS uses \E9 followed by a space — and that trailing space is required, because CSS escapes are variable-length hexadecimal and the space is what marks the end. Leaving it out means the next character gets absorbed into the escape, which produces a completely different glyph or nothing at all.

URL encoding is the odd one out: it escapes bytes rather than characters, so é becomes %C3%A9 — two escapes for one character, because that is its UTF-8 representation. This is why a URL containing accents looks so much longer than the text, and why percent-decoding a string byte by byte gives nonsense if you do not reassemble the UTF-8 afterwards.

Double-escaping is the failure to watch for. Text that has been escaped twice shows \\u00E9 or é, and decoding it once leaves an escape still visible. That means something in your pipeline is escaping an already-escaped value — worth finding, because it will happen again.

Questions

CSS escapes are variable-length hex, so the space marks where the escape ends. Without it the next character is absorbed into it.

CSS Syntax — escapingMDN — String literals and escapes
Advertisement
300 × 250
Was this tool any good?
INTERNAL SIGNAL ONLY · WE USE IT TO FIND TOOLS WORTH REBUILDING