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.

Upload File

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.

How to Edit JSON Online

  1. Get it in. Paste under Enter or paste JSON, or press the file button to open a .json file. A PNG gets an Invalid File message.
  2. Edit in place. A red gutter marker and a status line such as parse error on line 1 flag a problem, and Ctrl+Z steps back.
  3. 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. 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.

ButtonWhat it doesTested
Format JSON data (Ctrl+I)Indents with two spacesYes, two-space indent
Compact JSON data (Ctrl+Shift+I)Strips whitespaceYes, one line
Sort contentsOpens a Field and Direction dialogYes, lists field names
Filter, sort, or transform contentsJMESPath wizard, query and previewYes, live Preview
Repair JSONFixes quotes, comments, commasYes, best effort
Undo last action, RedoSteps back and forwardYes, Ctrl+Z

Repair is a best guess. It turned {'a': 1, b: 'x', // c 'd': [1,2,],} into valid JSON with the same keys and values, and fixed True and None. It also quoted undefined, NaN and hello world, which may not be what you meant.

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, so 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 one Chromium test run, a 3.8 MB array of 40,000 objects loaded in 1.1 seconds, then Format took 5.9 seconds and Download JSON 5.2 seconds.

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. For anything else:

For schema.org rules, use the Schema Markup Validator. Still choosing a format? The JSON versus XML guide compares them.

Frequently Asked Questions

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 the file button and pick a .json file, or paste a payload under Enter or paste JSON. Change the values, 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. Check the output.

Is my JSON sent to your server?

Not while you edit. Pasted text and opened files never travel in a request. 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 a 3.8 MB array loaded in about one second and took about six seconds to format, 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.
Share on Social Media: