JSON Formatter & Validator

Format, validate, explore, and convert JSON — all in your browser. Data never leaves your device.

Ctrl+Enter Format Ctrl+M Minify Ctrl+K Clear
Line :
Input

Drop JSON file here


                        
Formatted output appears here
Click key to copy JSONPath
Tree view appears after formatting

Supports: $.key $[0] $[*] $..key (recursive)


                        
Enter a JSONPath expression and press Query or Enter.
Stats Keys: Strings: Numbers: Booleans: Nulls: Arrays: Objects: Depth: Raw: Formatted: Minified:

Fetch JSON from URL

Note: The URL must allow CORS requests from this origin.

Format & Beautify

Instant pretty-print with 2, 4 spaces or tab indent.

Validate & Debug

Real-time error detection with exact line & column.

Tree Explorer

Collapsible tree — click any key to copy its JSONPath.

Convert

Export to CSV, XML, or YAML in one click.

Frequently Asked Questions

Is my data secure?

Completely. All processing happens in your browser using JavaScript. No data is ever sent to any server. You can even use this tool offline.

What is the "Repair" button?

It attempts to fix common JSON mistakes like trailing commas, unquoted keys, and single-quoted strings — converting them to valid JSON automatically.

How does JSONPath work?

Use $ as the root. $.name gets a top-level key, $.users[0] gets the first array item, $.users[*].email gets all emails, $..id searches recursively for all id fields.

Can I format large JSON files?

Yes. For very large files (multi-MB), use the Upload button. Processing happens locally so there are no size limits imposed by the server.

Why use "Sort Keys"?

Sorting keys alphabetically makes JSON easier to read, compare across versions, and diff in version control — especially for configuration files.