JSON Escape / Unescape String Online
Escape text for embedding in JSON strings (\n, \", \\, \uXXXX) or unescape back to raw text. Free, instant, 100% in your browser.
Input · text0 chars
Output · text0 chars
🔒 100% private: this tool runs entirely in your browser. Your data is never uploaded, stored or logged anywhere.
How to json escape
- Paste raw text, get the escaped JSON string (quotes included).
- Switch to Unescape and paste a JSON string to get raw text back.
- Copy the result — ready to paste into code or config.
FAQ
What gets escaped?
Exactly what JSON requires: ", \, control characters (\n, \t, \r, …) and non-ASCII control codepoints.
Does escape include the surrounding quotes?
Yes — output is a complete, valid JSON string literal you can paste directly into code.
Can I unescape a bare (unquoted) string?
Yes — unescape mode accepts both a quoted JSON string and a bare escaped string like a\nb.