UtilDojo

Popular

Menu

JSON Validator — Check JSON Syntax Online

  • This tool runs entirely in your browser. Nothing you enter or upload is sent to a server.

Input

Tab indents · Shift+Tab outdents · Esc then Tab moves on

Your formatted JSON shows up here

Paste or type on the left, upload a file, or drop one onto the input.

Waiting for JSON

JSON & data

About this tool

The validator parses your input with the same strict JSON rules browsers and servers use, and reports the first error with its line, column and a caret pointing at the problem character. It updates as you type, so you can fix a problem and see the message clear at once.

Paste a document to see how it looks. For {"name": "Asha", "tags": ["a", "b",]} the tool points at the trailing comma before the closing bracket. Other typical findings are single-quoted keys (“Expected double-quoted property name”), extra text after the closing brace, leading zeros in numbers such as 01, an unterminated array, and a missing comma between properties. Only the first error is shown, because everything after it may be a side effect of that one mistake, so fix it and look again.

For valid JSON you get a quick structural summary — number of keys, objects and arrays, and the maximum nesting depth — which is useful when checking API responses or config files. A sudden jump in depth often means a payload is wrapped in an extra envelope.

Validation is instant and local; you can safely paste production payloads. Remember what “valid” means here: the text is well-formed JSON. It does not mean the data is correct for your API, that field names are right, or that numbers are in range. If you need the tidied-up version of valid JSON, the JSON Formatter indents, sorts keys and minifies it.

Frequently asked questions

Does this validate against a JSON Schema?

Not here: this page checks syntax only. It tells you whether the text is well-formed JSON, not whether it matches a particular schema. To check data against a schema, use the JSON Schema Validator, which lists every problem with its path.

Are comments allowed in JSON?

Not in standard JSON. Formats like JSONC or JSON5 allow them, but JSON.parse and most APIs will reject comments.

Can I fix the errors automatically?

Yes, for the common ones. This page is the JSON Formatter, so switch on the Repair option above the input: it removes trailing commas and comments, fixes single quotes and unquoted keys, and lists each change it made.

Can I validate very large files?

Yes. Files of several megabytes validate quickly because parsing uses your browser’s native JSON engine.

Why does the error point to a place after the real mistake?

A parser can only notice a problem when it reaches text that does not fit. A missing quote or bracket is often reported at the next token, so check just before the caret as well as at it.

Is an empty input valid?

No. Nothing is shown until you type something, and an empty string is not a JSON document. The smallest valid documents are values such as {}, [] or 0.

Read the guide

Related tools