Escape JSON String
Escape a string so it can be embedded inside a JSON string value (newlines, tabs, and quotes are backslash-escaped), or unescape it back to the original text.
Instructions
Escapes text so it can live inside a JSON string value, or unescapes it back to the original.
- Paste the text into the input.
- Choose Escape (raw text → JSON-safe) or Unescape (JSON-safe → raw text).
- The output updates as you type; Copy takes the result.
Tips
- Escaping covers
",\, newlines, tabs and other control characters — the ones that would otherwise break the JSON around them. - Common use: pasting a whole JSON document as the value of another JSON field, or reading a log line that arrived escaped.
- Hit Example and pick a direction to load a sample already in the right shape.