Skip to content
NMSnabbit.

Unescape String

Decode backslash escape sequences back into readable text.

Encoders & Decoders Runs in your browser

What does unescape string do?

The reverse of escaping: \n turns back into a real line break, \t into a tab, \" into a plain quote. Hex (\x41), four-digit unicode (\u0041) and code-point (\u{1F600}) sequences decode too, so an escaped emoji comes back as the emoji. A backslash before an ordinary letter is left alone rather than swallowed, so nothing in your text goes missing.

How to use the Unescape String

  1. 1 Paste the escaped string, backslashes included.
  2. 2 Sequences from \n through \u{...} decode to their real characters.
  3. 3 Anything that is not a valid escape is preserved as-is.
  4. 4 Copy the readable text.

What you can use it for

  • Reading an escaped string from a log or JSON value.
  • Turning \n sequences back into real line breaks.
  • Recovering text copied out of source code.
  • Checking the result of an escape-string step.

Frequently asked questions

What escape notations can it decode?
The short set (\n, \r, \t and friends), hex \xNN, four-digit \uXXXX and braced code points like \u{1F4A9}. All are converted back to real characters.
What happens with a backslash before a normal letter?
The letter is kept and the backslash dropped, mirroring how JavaScript treats unknown escapes, so malformed input degrades gently instead of erroring.
Is this the tool for %20 or & style text?
No. Percent sequences are URL encoding and & is an HTML entity; each has its own decoder. This one only reverses backslash escapes.

Related tools

More Encoders & Decoders

More tools like this:

All Encoders & Decoders