“We noticed you may be using an ad blocker. SEO Site Checker relies on ads to keep our SEO tools free. Please consider disabling your ad blocker to support us - thank you!”“We noticed you may be using an ad blocker. SEO Site Checker relies on ads to keep our SEO tools free. Please consider disabling your ad blocker to support us - thank you!”
JSON Editor: Edit, Repair and Download JSON Online
Paste JSON, open a file or load a public URL, edit it with live parse-error marking, then copy or download it. Free, no account needed.
Result
What This JSON Editor Does
Quick answer: This online JSON editor is a code editor with line numbers, syntax highlighting and an error marker. Paste JSON, open a file or use Load from URL, then press Download JSON or Copy to Clipboard.
It has no tree mode, no form mode and no table mode, so it is not a viewer and every change is typed text. Format and Compact only change whitespace, so long numbers, trailing zeros and repeated keys stay exactly as you typed them.
How to Edit JSON Online
Get it in. Paste under Enter or paste JSON, or press Upload File to open a .json file from your device. Despite the name, our code does not upload it: the file is read in your browser. A file saved as UTF-8 with a byte order mark, as UTF-16 or as Windows-1252 opens as readable text. A PNG gets an Invalid File message.
Edit in place. A red marker in the gutter and a red icon in the status bar flag a problem; hover over the icon for a message such as parse error on line 1. Ctrl+Z steps back, Ctrl+F opens a search box and Ctrl+H adds a Replace with field plus Replace and All buttons.
Take it out. Press Download JSON to get json-editor.json, or Copy to Clipboard.
Load from URL is the one route through our server. Our server fetches the file for you, so a public JSON file loads even when its host sends none of the CORS headers a browser fetch would need. It takes public addresses only, up to 3 MB, so http://127.0.0.1/x.json comes back as: That address is not allowed.
Invalid input: Download JSON refuses broken text and shows the parser message, such as Parse error on line 1 with Expecting 'STRING', got '}' for {"a":1,}. The JSON syntax diagrams show what is allowed.
Format, Compact, Repair, Sort and Transform
Toolbar buttons are icons, so hover for the tooltip, which starts with these names. All were clicked in Chromium.
Button
What it does
Tested
Format JSON data (Ctrl+I)
Indents with two spaces
Yes, two-space indent
Compact JSON data (Ctrl+Shift+I)
Strips whitespace
Yes, one line
Sort contents
Opens a Field and Direction dialog
Yes, lists field names
Filter, sort, or transform contents
JMESPath wizard, query and preview
Yes, live Preview
Repair JSON
Fixes quotes, comments, commas
Yes, best effort
Undo last action, Redo
Steps back and forward
Yes, Ctrl+Z
Repair is a best guess. It turned {'a': 1, b: 'x', 'd': [1,2,],} into {"a": 1, "b": "x", "d": [1,2]}, and it changed True and None to true and null. It also quoted undefined, NaN and hello world, which may not be what you meant. A // comment is removed together with the rest of its line, so on one line {'a': 1, b: 'x', // c 'd': [1,2,],} comes back as {"a": 1, "b": "x"} and the d key is gone. Put comments on their own line.
Long Numbers and Repeated Keys Are Kept as Written
A browser stores every number as a 64-bit float, exact only up to 9007199254740991. A tool that parses and rewrites your text turns 12345678901234567890 into 12345678901234567000 and 1.10 into 1.1, as JSON.stringify in JavaScript does. We keep your raw text instead. On {"id": 12345678901234567890, "price": 1.10}, Format and Compact changed only the whitespace and kept both numbers exactly, and Download JSON saved the text as typed.
Repeated keys survive too, with no warning, although RFC 8259 says names should be unique. The JSON Validator does warn. Sort and Transform rebuild the document from browser values, so when the text holds a number a browser cannot hold exactly, a repeated key or numeric keys it would reorder, you first get a Continue? prompt, and Cancel leaves the text alone.
Large Files, Privacy and What Runs Where
No code caps pasted text, so your device sets the limit. In our Chromium test runs, an array of 40,000 small objects, about 4 MB, loaded in under two seconds, while Format and Download JSON each took several seconds. A slower device or a busy machine takes longer.
Everything else, Repair and Copy to Clipboard included, stays in the browser: the only first-party request we saw came from Load from URL.
Other JSON Tools When You Need Something Else
This editor changes text and checks syntax only. It has no compare view, no JSON Schema validation and no share link. For anything else:
JSON Viewer: read a document as a collapsible tree.
Frequently Asked Questions (FAQs) is a list of common questions and answers provided to quickly address common concerns or inquiries.
How do I edit a JSON file online?
Press Upload File and pick a .json file from your device, or paste a payload under Enter or paste JSON. Change the values, search and replace with Ctrl+F and Ctrl+H if you need to, check that no red marker shows in the gutter, then press Download JSON to get json-editor.json. Invalid JSON is refused with the parser message.
Is there a tree view to edit keys and values?
No. This editor is text based, with line numbers and syntax colors, so you change keys and values by typing. Sort contents and the JMESPath transform dialog can reshape arrays, but for a collapsible tree, open the JSON Viewer instead.
Does the JSON editor fix broken JSON?
Repair fixes single quotes, unquoted keys, a trailing comma, comments, True and None. It guesses, though. Undefined and NaN turn into strings, and plain text becomes a string too, so read the result before you save it. A // comment also removes the rest of its line, so put comments on their own line.
Is my JSON sent to your server?
Not while you edit. Our code does not send pasted text or opened files anywhere, and Format, Compact, Repair, Copy to Clipboard and Download JSON run in your browser as well. Only Load from URL sends the address to our server, which fetches public files up to 3 MB and refuses a local address such as 127.0.0.1.
Will long numbers or repeated keys be changed?
Format, Compact and Download keep your text as written, 12345678901234567890 and duplicate keys included. Sort and Transform rebuild the document, so on such a document they ask you to confirm first. The JSON Validator will point out repeated keys to you.
How large a JSON file can I edit?
No code caps pasted or opened text. In our test runs a 4 MB array of 40,000 small objects loaded in under two seconds, while Format and Download JSON each took several seconds, so the limit is your device. Load from URL accepts up to 3 MB. A phone will take longer, so split a very large file first.
We use cookies to personalize content and ads, to provide social media features and to analyze our traffic. You consent to our cookies if you continue to use our website.
Install SEO Site CheckerFree SEO tools - always in your pocket.