Skip to the tool
GigaJSON

JSON Escape and Unescape

All tools
Guides Open GigaJSON

Turn any text into a valid JSON string, with quotes, backslashes, line breaks and control characters escaped. Or go the other way and turn an escaped JSON string back into plain text.

How to use it

  1. Choose Escape or Unescape.
  2. Paste the text or the JSON string.
  3. Copy the result.

Private

This tool runs in your browser: nothing you paste is uploaded, and nothing is kept after you leave. If your connection drops while you're here, the tool keeps working. When one tool isn't enough, GigaJSON opens your data with a tree, a table, JSONPath/JMESPath/jq queries, transforms, diff and history.

Questions

What gets escaped?

Double quotes, backslashes, line breaks, tabs and other control characters. It's the same as what JSON.stringify does.

Unescape says the input is invalid

Unescape expects one JSON string, with or without the quotes around it, e.g. "line one\nline two".

All tools