JSON Key Sorter
Sort object properties throughout a JSON document while retaining array order.
Loading tool…
How to use JSON Key Sorter
Normalize property ordering before comparing configuration files or reviewing generated data. Sorting applies recursively to objects, including objects inside arrays, without reordering the arrays themselves.
- Paste JSON containing objects to reorder.
- Select Run tool to sort property names recursively.
- Review the result, then copy it or download the generated file.
Good to know
- Up to 100,000 input characters, 10,000 values, and 40 nesting levels. Standard JSON numbers use JavaScript precision; duplicate keys retain their last value.
- Uses JavaScript key ordering: integer-like properties appear numerically before other keys. Remaining keys use UTF-16 lexical order. This is not a cryptographic canonicalization scheme.
Common questions
Can I use this for canonical JSON signatures?
No. Signature formats need their exact canonicalization specification, including number and string handling.
Keep going with related tools
All data →JSON Diff
Compare JSON values structurally and list added, removed, or changed paths.
DeveloperJSON Formatter
Format and indent valid JSON in your browser, with downloadable output and clear syntax errors.
DataJSON Minifier
Remove unnecessary JSON whitespace while preserving the parsed data structure.
DataJSON String Escaper
Encode text as a JSON string literal or decode one JSON string into readable text.
DataJSON Flattener
Flatten nested JSON into a JSON Pointer map of leaf values without ambiguous dotted keys.
DataJSON Path Query
Select JSON values using a restricted, safe path grammar with array indices and wildcards.