JSON Key Sorter
Recursively sort JSON object keys alphabetically while preserving array order—great for stable diffs and tidy config files. Everything runs in your browser.
FAQ
When is key sorting useful?
Sorting both sides before a diff exposes real differences instead of ordering noise—also handy for keeping config files consistent.
Why keep array order?
Object key order carries no meaning, but array order is data. Only keys inside array elements get sorted.
Does it handle JSON with comments?
Standard JSON only—strip comments and trailing commas (JSONC) first.
Related tools
Format JSON for readability or minify it to a single line. Syntax errors are shown instantly.
Convert JSON data into readable YAML. Everything runs in your browser—no data leaves your device.
Compare two texts line by line and highlight added and removed lines.
Convert a JSON array into CSV. Arrays of objects use their keys as the header. Everything runs in your browser—no data leaves your device.