YAML Validator
Check YAML parses and find the line where the indentation goes wrong.
Fix broken JSON: trailing commas, single quotes, unquoted keys and comments.
The JSON Repair tool reads the near-miss dialects people actually paste — JavaScript literals, Python dicts, commented configs, truncated responses — and writes back strict JSON, listing every assumption it made along the way.
Most broken JSON is not really broken — it is a near-miss dialect. A JavaScript object literal, a Python dictionary printed to a log, a config file with comments, or a response that was truncated before its brackets closed. The repairer reads all of those and writes back strict JSON.
It handles unquoted keys, single and backtick quotes, trailing and doubled commas, // and /* */ and # comments, Python's True, False and None, NaN and Infinity, raw line breaks inside strings, hex and underscore-separated numbers, and documents that simply stop. Every change is listed under the output, so you can see exactly what was assumed rather than trusting a silent fix — which matters when the thing being repaired is a log line you are about to draw a conclusion from.
Nothing is repaired silently. The list under the output tells you whether a comma was dropped or a truncated array was closed — a very different situation.
Unquoted keys, single and backtick quotes, // and /* */ and # comments, and Python's True, False and None all read correctly.
A response that stops mid-array is closed at the cut point so you can read what did arrive.
Hex literals, underscore separators and leading plus signs are rewritten; NaN and Infinity become null, because JSON has no literal for them.
The repaired document comes back indented and readable, not as one unbroken line.
A JavaScript literal, a Python dict, a commented config or a truncated response all work.
Every assumption the repairer made is listed under the result, in plain English.
The repaired document is valid strict JSON, formatted with the indentation you choose.
Take the fixed document to your clipboard or download it as a .json file.
It fixes the common near-miss dialects and truncation. Text that is not structurally JSON at all — an HTML error page, for example — cannot be repaired into a document, and the tool says so rather than guessing.
Only where JSON has no equivalent. NaN and Infinity become null because JSON has no literal for them, and that substitution is always listed in the repair notes.
Yes. A response truncated mid-document is closed at the point it stops, and the repair list tells you it happened so you know the tail is missing rather than empty.
Read the repair list first. A removed trailing comma changes nothing; a closed-off truncated array means you are looking at partial data, which is a very different situation.
What people who use the JSON Repair think of it. Reviews come from visitors and are posted as written.
No ratings yet
Yours would be the first.
0 reviews
Newest first
No reviews yet
Be the first to rate the JSON Repair. It takes half a minute and no account.
Write the first reviewCheck YAML parses and find the line where the indentation goes wrong.
Collapse a SQL query to one line and strip its comments.
See a float’s sign, exponent, mantissa and its exact decimal value.
Turn a block of text into a comment in any language, wrapped and aligned.
Turn a URL query string into structured JSON, including nested and repeated keys.
Generate an MD5 hash of any text, with a straight answer about when not to.
Work out the gap between two dates, in every unit including working days.
Convert a start and end address into the smallest set of CIDR blocks.