JSON Escape / Unescape

Escape text for embedding in JSON strings, and unescape back

How to use

  1. Type or paste text to escape into the left pane; the escaped JSON string literal appears on the right.
  2. Paste an escaped string to unescape it back to plain text.
  3. Both directions run as you type.

About this tool

Embedding user text into JSON — config files, prompt templates, API payloads — fails on the same four characters every time. This tool applies the exact escaping JSON.parse expects, and unescapes back losslessly, including surrogate pairs for emoji.

Frequently asked questions

Which characters get escaped?

Quote, backslash, and control characters (newline, tab, carriage return) per the JSON spec, plus non-ASCII characters as \uXXXX for maximum compatibility.

Why does escaping matter?

Raw quotes or newlines inside a JSON string break parsing. Config generators, log shippers, and code-as-data pipelines all need correct escaping.

Is anything sent to a server?

No. Escaping happens locally in your browser.

Related tools