JSON Escape
Escape any text — quotes, newlines, tabs, unicode — so it can be safely embedded as a JSON string value.
When you need JSON escaping
Any time free-form text goes inside a JSON string: an error message with quotes in it, a multi-line SQL query in a config value, HTML in an API payload, a file path full of backslashes. Raw, these characters either break the JSON or silently change its meaning. Paste the text on the left, press Escape, and the right pane holds a string body you can drop between two double quotes in any JSON document.
What gets escaped
| Character | Becomes | Why |
|---|---|---|
double quote " | \" | would end the string |
backslash \ | \\ | starts escape sequences |
| newline | \n | control chars are forbidden raw |
| carriage return | \r | same |
| tab | \t | same |
| other control chars | \u00XX | required by RFC 8259 |
Everything else — including emoji, accented letters and non-Latin scripts — passes through unchanged, because JSON is UTF-8 native and does not require escaping printable unicode. Forward slashes are also left as-is; \/ is legal but unnecessary.
Example
Input: He said "hello"
on two lines
Output: He said \"hello\"\n on two linesGot escaped text and need it readable again? The JSON Unescape tool reverses this exactly.
Frequently asked questions
Does the output include the surrounding double quotes?
No — the tool outputs the escaped string body, ready to paste between your own quotes. That makes it composable: you can concatenate escaped fragments or insert the result into an existing document without stripping anything.
Do emoji and non-English characters need escaping?
No. JSON is UTF-8 by standard, so 你好, éàü and 🚀 are all legal inside strings as-is. Only the double quote, the backslash and control characters below U+0020 must be escaped. Some legacy systems prefer \uXXXX for everything non-ASCII, but it is not required.
What is the difference between JSON escaping and HTML escaping?
Different target languages: JSON escaping protects " \ and control characters with backslashes; HTML escaping protects < > & with entities like &lt;. Text embedded in a JSON string inside an HTML page may legitimately need both, applied in the right order.
My text is already escaped — what happens if I escape it again?
Every backslash gets doubled: \n becomes \\n. That is correct behaviour (the tool cannot know your intent) but usually not what you want — unescape first, then escape once.