Bring your string
Paste a payload, upload a file, or drop it into the editor.
Convert a string to JSON online, including escaped and double-encoded payloads.
Format, validate, and download the result in your browser.
Your formatted JSON will appear here.Use this string to JSON converter to parse escaped JSON online. The outer quotes in this example wrap an object in a string; String → JSON unwraps that layer and formats the result. An input containing a JSON array produces an array.
"{\"name\":\"Maya\",\"attempt\":2}"{
"name": "Maya",
"attempt": 2
}For more examples, read how to convert a string to JSON. If parsing fails, check our guide to fixing common JSON errors, or learn how escaped and double-encoded JSON works.
The converter is the quickest way to inspect a payload. In code, each language has one standard call. If the result is still a string, the JSON was encoded twice, so parse it again.
const data = JSON.parse(text);
// Still a string? It was encoded twice.
const value = typeof data === "string" ? JSON.parse(data) : data;import json
data = json.loads(text)
if isinstance(data, str):
data = json.loads(data)using System.Text.Json.Nodes;
JsonNode? data = JsonNode.Parse(text);
string? name = (string?)data?["name"];Step-by-step guides: JavaScript, Python and C#.
Paste a payload, upload a file, or drop it into the editor.
We unwrap escaped layers. You choose the indentation and key order.
Copy the result or save a JSON file. Ready for whatever comes next.
Simple by design. Useful by nature.
Use valid JSON, a quoted JSON string, escaped JSON, or a payload encoded multiple times. The converter unwraps JSON string layers automatically.
No. Converter input stays in your browser and is never stored or uploaded. Page analytics runs only if you accept it in the cookie banner. See our Privacy Policy.
Each layer is one round of string encoding. One layer is normal for JSON stored as text; two or more means the payload was serialized twice. JSON unescape explains the details.
JavaScript cannot represent every integer above 9,007,199,254,740,991 exactly, so such values may change when parsed. Send long IDs as strings. Read why large JSON numbers change.
JSON requires double-quoted keys and strings, without comments or trailing commas. The error message points to the position that needs attention.
Yes. Select JSON → String to create a single escaped JSON literal for use in code or a payload.