Your JSON formatter “isn’t working.” Use this decision path first:
- Site/network problem: page blank, TLS error, timeout
- HTML or wrong format: you pasted an error page, log wrapper, or non-JSON
- Syntax issue: missing comma, quote, or bracket (repair guide)
- Size or tool limit: huge payload stalls the tab
This guide helps you tell those cases apart, extract a payload from messy log text, and inspect the result in the free online formatter.
Page problem versus invalid input
Start with the cheapest checks:
- Does the formatter page load at all? Blank screens, TLS errors, and timed-out tabs are infrastructure or network issues - not a verdict on your JSON.
- Does paste produce a parse error? That usually means the text isn’t valid JSON yet (missing comma, bad quotes, truncated copy).
- Does it format, but look wrong? You may have pasted an HTML error page, a log line wrapper, or a string that only contains JSON.
If the site is unreachable, you still need the payload readable. Open a tool that already runs in your browser so you aren’t waiting on someone else’s uptime.
Pretty Payload’s free web demo processes JSON locally after the page loads. No signup for a first look. Inspected payloads are not uploaded for processing.
HTML error pages masquerading as JSON
A classic trap: you copy from DevTools or a proxy and get something like:
<!DOCTYPE html>
<html><body>502 Bad Gateway</body></html>
Paste that into a JSON formatter and you’ll get a parse failure that has nothing to do with your API’s schema. Clues:
- Starts with
<!DOCTYPE,<html, or a framework error template - Content-Type was
text/htmlin the Network panel - Body mentions Cloudflare, nginx, or “application error”
Go back to the response that returned application/json (or extract the JSON object from a larger log line). Then format that slice alone.
Extract the payload from log text
Logs love to wrap JSON in noise:
2026-09-15T19:02:11Z INFO demo_1042 body={"request_id":"demo_1042","status":"needs_review"}
Copy only the object (from { to }), not the timestamp prefix. If the value is escaped inside quotes, see escaped JSON in logs and the broader nested JSON guide.
Fix a small syntax error (missing comma)
Strict formatters fail fast on invalid JSON. That’s correct behavior - and it’s why “formatter not working” often means “input isn’t JSON yet.”
Broken sample (fictional):
{
"request_id": "demo_1042",
"status": "needs_review"
"customer": { "name": "Example Company" }
}
There’s a missing comma after "needs_review". Pretty Payload can repair that class of issue and surface a notice such as Repaired · View repairs with a note like “Inserted a missing comma.”
Repaired result:
{
"request_id": "demo_1042",
"status": "needs_review",
"customer": {
"name": "Example Company"
}
}
Successful repair is not the same as strict validation of the original text. Review the repair details, keep the original when fidelity matters, and treat automatic fixes as a debugging aid - not a silent rewrite of production data. More detail: how to repair malformed JSON.
If you only need a pass/fail check versus pretty-print, formatter vs beautifier vs validator separates those jobs.
When the output looks “wrong” but parsed fine
Sometimes the formatter worked and the surprise is elsewhere:
- Large integer IDs can change in plain JavaScript parsers - see why large JSON IDs lose a digit.
- Nested string payloads look like a wall of backslashes until you expand them.
- Key order in a sorted view may differ from what you copy (Pretty Payload’s sort changes the view; copied JSON keeps original key order).
When the producer needs fixing instead
Interactive repair helps you read a bad payload once. It does not replace fixing the service that emitted it. Prefer failing loudly in CI when your contract requires strict JSON. Use local repair for triage, then patch the producer.
Try it
- Open the free web demo.
- Paste the missing-comma sample above (or your own fictional reproduction).
- Expand Repaired · View repairs, confirm the change, then use Copy JSON or Copy Minified.
For recurring clipboard work, add Pretty Payload to Chrome (10 free opens without signup; then a 30-day email trial, no card).
One missing comma shouldn’t own your afternoon. Identify whether the page, the wrapper, or the syntax failed - then inspect locally and get back to the real bug.