JSON Tools
These JSON tools run entirely in your browser. Paste or drop a document and it is parsed, compared, reformatted or validated on your own machine — the payload is never uploaded. Each tool implements RFC 8259 strictly rather than relying on the browser's JSON.parse, so errors carry a line and a column.
Format
JSON Formatter
JSONCIndent, sort keys and strip comments with configurable output.
Format a payloadJSON Beautifier
PrettifyPretty-print minified JSON with custom indentation.
Expand minified JSONJSON Pretty Print
11 languagesFormat it here, or copy the line that does it in your language.
Pretty-print JSONJSON Minifier
GzipStrip whitespace and measure the real gzip wire size.
Shrink a payload
Validate
JSON Validator
RFC 8259Validate syntax with exact line and column, and repair it in one click.
Find the broken lineJSON Parser
AnalysisParse a document and see what it actually contains.
Analyse a documentSchema Generator
2020-12Infer a Draft 2020-12 schema from samples and validate against it.
Infer a schema
Convert
JSON to CSV
RFC 4180Convert records to a spreadsheet grid, nesting and all.
Make a spreadsheetCSV to JSON
RFC 4180Parse a spreadsheet export into records, quoting and all.
Parse a spreadsheetJSON Stringify
EscapeEscape a document into a string literal for embedding.
Escape a documentJSON Unescape
RecoverRecover a document buried in escapes inside a log line.
Recover a documentJSON to TypeScript
InterfacesGenerate interfaces from a sample, optionality and all.
Generate interfacesJSON to Go
StructsGenerate structs with json tags that actually marshal.
Generate structsJSON to Python
DataclassGenerate dataclasses, TypedDicts or Pydantic models.
Generate classesJSON to C#
ClassesGenerate classes or records with the right attributes.
Generate classesJSON to Java
RecordsGenerate records or POJOs, boxing what can be absent.
Generate classes
When should you use a browser-based json tool?
Almost every JSON tool on the web is a form that posts your document to a server. For a snippet from a tutorial that is fine. For the actual payload you are debugging it is rarely fine at all: production JSON tends to carry access tokens, customer records, internal hostnames and account identifiers, and pasting it into an unknown endpoint hands all of that to somebody else’s access log. In a regulated environment it is not a judgement call, it is a reportable incident.
The tools here take the server out of the question entirely. The page you load is static HTML and JavaScript; when you paste a document, it is parsed by code already running in your tab. There is no request to inspect and no endpoint to trust, which is a much stronger position than a promise not to look.
That decision also makes them faster. There is no upload, no queue and no round trip, so a 2 MB document formats in the time it takes to repaint rather than the time it takes to cross the Atlantic twice. And it means they work on an aeroplane, on a locked-down corporate network, and inside a VPN that blocks everything it does not recognise.
The engines are written by hand rather than assembled from packages, which matters more than it sounds. The parser is iterative rather than recursive, so a deeply nested document reports an error instead of blowing the JavaScript call stack — there is a test in the suite that feeds it twenty thousand levels of nesting. Every key that comes from your document is assigned through an own-property guard, so a payload containing __proto__ cannot alter the behaviour of the page that is inspecting it. These are not theoretical concerns; they are the two ways JSON tools actually break.
Where a standard exists, it is followed exactly: RFC 8259 for the grammar, RFC 6902 for patch documents, RFC 7386 for merge patches, and JSON Schema Draft 2020-12 for inference and validation. When a tool has to make a choice the standard leaves open — how to match array elements when comparing, whether to sort keys on output — it is exposed as a setting rather than hard-coded, and the reference table on each page says what the setting does at the edges.
If you are not sure where to start: JSON Validator for a document that will not parse, JSON Diff for two documents that should match and do not, JSON Formatter for something unreadable, and Schema Generator when you need to describe the shape of a response you did not write.
Frequently asked questions
Which JSON tool should I use to find why my payload is rejected?
Start with the JSON Validator. It reports the first syntax error with an exact line and column and a caret pointing at the offending character, and it classifies the common causes separately — a trailing comma, a single-quoted string, an unquoted key, a mismatched bracket, a byte-order mark, or a smart quote pasted from a word processor. If the document is close to valid, the one-click repair will fix it and show you exactly what it changed before you accept.
Why does JSON Diff report no changes when the two documents look different?
Because object key order carries no meaning in JSON. RFC 8259 defines an object as an unordered collection, so {"a":1,"b":2} and {"b":2,"a":1} are the same document and a semantic diff says so. A line-based tool like Unix diff compares the serialised text and reports every reordered key as a change, which is why it is close to useless on formatted API responses.
Is there a size limit?
Tools that run on the main thread stop at 8 MB, which is the point at which a single parse starts to make the tab feel broken. JSON Diff offloads to a Web Worker and accepts up to 100 MB. Above either ceiling the tool refuses with a clear message rather than freezing — a 50 MB comparison still takes real time, but the interface stays responsive while it runs.
Do these tools handle JSONC — JSON with comments?
The JSON Formatter does. It accepts // and /* */ comments and trailing commas on input and can strip them on output, which is what you want for tsconfig.json, .eslintrc.json and similar config files. The Validator is deliberately stricter: it holds the document to RFC 8259 exactly, because when you are asking whether an API will accept a payload, a permissive answer is the wrong one.
Can I use these offline?
Yes. Load any tool page once and it keeps working with the network off — disconnect Wi-Fi and try it. There is nothing on the other end to talk to: the site is a static export with no API routes, and every engine is JavaScript already running in your tab.
What else is on ToolsByUs?
- PDF ToolsMerge, split, rotate and convert PDFs without uploading them.
- Image ToolsCompress, resize and convert images in the browser.
- Creator ToolsResize and optimize banners, avatars, emotes and covers for every platform.
- Color ToolsPick, convert, check contrast and test for colour blindness.
- Text ToolsDiff, convert and reshape plain text and code.
- Encoding ToolsBase64, URL encoding, hashing and token inspection.
- Generator ToolsIdentifiers, placeholder content and codes.