Format or minify JSON, compare two JSON values structurally, or generate TypeScript interfaces from an object-shaped JSON document.
Need more than a template?
I build internal tools, integrations and full-stack products for startups and growing teams.
Full-stack engineering →Paste JSON to format it with two-space indentation, minify it, or find out why it is invalid. The compare view lists which keys were added, removed or changed between two documents, and the TypeScript view turns a JSON object into interfaces you can paste into a codebase.
// input
{"id":1,"name":"Aslam","tags":["devops","ai"],"profile":{"active":true,"score":9.5}}
// output
export interface RootProfile {
active: boolean;
score: number;
}
export interface Root {
id: number;
name: string;
tags: string[];
profile: RootProfile;
}Nested objects become their own interface, named after the key.
// left
{"hello":"world"}
// right
{"hello":"there"}
// result
~ hello: world → thereThese are the tool's two starting documents. A key that exists only on the right appears with +, and one that exists only on the left with -.
JSON does not allow a comma after the last item. It is the most common reason a hand-edited file fails.
Keys and strings need double quotes, and JSON has no comments. Config files that allow either are usually JSON5 or JSONC, not JSON.
JavaScript parses numbers as 64-bit floats, so integers above 9007199254740991 lose precision. IDs that long are safer as strings.
The standard allows them but does not say what they mean. JavaScript keeps the last value and drops the rest without a warning.