About the JSON to Multi-line
Expand single-line JSON into nicely indented, multi-line JSON that's easy to read.
Key features
- Expands single-line JSON into readable multi-line JSON
- 2-space, 4-space or tab indentation
- Validates input with line and column errors
- Ideal for log lines, env vars and API responses
- Copy or download the result
- Runs in your browser
Make one-line JSON readable
Logs, environment variables, network traces and compact API responses deliver JSON on a single line. It's efficient but nearly impossible to read once it's longer than a sentence. JSON to Multi-line expands it with proper indentation so you can see the structure.
{"order":{"id":1001,"items":[{"sku":"A1","qty":2}],"paid":true}}
becomes
{
"order": {
"id": 1001,
"items": [
{
"sku": "A1",
"qty": 2
}
],
"paid": true
}
}
Where one-line JSON comes from
- Application logs in JSON format (Serilog, Winston, Pino, Logback JSON encoders).
- Kubernetes and Docker logs viewed with
kubectl logsordocker logs. - Environment variables holding JSON configuration.
- Network tabs and HAR files, where response bodies are often minified.
- Message queues and webhooks.
Quick workflow for logs
- Copy the log line.
- Delete everything before the first
{and after the last}. - Paste it here; if it's full of
\", use JSON Unstringify instead.
Related tools
Go back to a single line with JSON to One Line. For interactive exploration, use the JSON Viewer.
How to use the JSON to Multi-line
- Paste your data into the input box, upload a file, or click Sample to try it out.
- Adjust the options above the editor if you need to (indentation, delimiter, and so on).
- The Multi-line appears instantly in the output panel. Any errors are shown with their line and column.
- Click Copy to copy the result, or Download to save it as a file.