JSON Diff Checker — Compare JSON Files & API Responses Free
Paste two JSON objects, responses, or config files and instantly see every difference. The Auto-format option pretty-prints both inputs before diffing — eliminating false positives from whitespace and key ordering differences. Fast, free, and entirely browser-side.
Why Pretty-Printing Makes JSON Diffs Useful
JSON is often transmitted in minified form — all on a single line with no indentation — to save bandwidth. When you try to diff a minified JSON against a formatted one, you get a useless single-line diff that tells you nothing meaningful. The Auto-format JSON checkbox solves this: it parses each input as valid JSON and re-serializes it with consistent 2-space indentation before computing the diff. The result is a clean, readable comparison where every changed key appears on its own line.
Common uses include comparing API responses between staging and production environments, auditing changes to configuration files like package.json or tsconfig.json, and reviewing infrastructure-as-code changes in JSON format. The diff highlights added keys in green, removed keys in red, and changed values in amber — making it immediately clear what changed between two versions of a JSON document. If your inputs are not valid JSON, the tool automatically falls back to a plain-text line diff.
For non-JSON structured data like YAML, TOML, or XML, the Compare Text Files tool handles those formats without auto-formatting. For general text comparison, use the Diff Checker. To understand more about how the underlying diff algorithm works, visit How It Works.
Common JSON Comparison Use Cases
Compare API Responses
Paste responses from staging and production API calls to see which fields differ. Auto-format normalizes minified responses so you see key-by-key differences, not a single-line blob.
Audit Config File Changes
Compare package.json, tsconfig.json, .eslintrc, or any JSON config before and after a dependency update to see exactly which settings changed.
Verify Data Migrations
Check that a data migration or transformation preserved the correct fields by comparing the source and output JSON objects. Spot missing keys and changed values instantly.
Debug Schema Drift
Compare JSON schemas or OpenAPI spec versions to identify breaking changes — removed required fields, type changes, or added constraints — before deploying.
Frequently Asked Questions
When enabled, TextCompare parses each input as JSON and pretty-prints it with 2-space indentation before running the diff. This eliminates false positives from formatting differences — a minified JSON and its formatted equivalent produce zero diff after auto-formatting. If either input is invalid JSON, the tool falls back to a plain-text diff automatically.
Copy the JSON body from your first API call (from Postman, curl, or your browser's DevTools Network tab) and paste it into the left panel. Copy the second response into the right panel. Enable Auto-format JSON, then click Compare. The diff shows every added key, removed field, and changed value, including deeply nested objects.
Yes. Use the upload button or drag-and-drop to load JSON config files like package.json, tsconfig.json, or .eslintrc.json directly. Auto-format JSON ensures consistent formatting so the diff reflects only real value changes. Enable "Ignore blank lines" if either file uses blank lines as visual separators between config sections.