JSON Formatter & Validator online

JSON - what is it?

I guess everyone heard and had contact with JSON somewhere. This is the most popular data exchange format nowadays, it is very simple in itself.

JSON (JavaScript Object Notation) is a simple data exchange format. Writing and reading data in this format is easy for people to master. At the same time, they read it easily and generate computers. Its definition is based on a subset of the programming language JavaScript, Standard ECMA-262 3rd Edition - December 1999. JSON is a text format, completely independent of programming languages, but uses conventions that are familiar to programmers using C-family languages, including C++, C#, Java, JavaScript, Perl, Python and many others. These features make JSON the ideal language for data exchange.

JSON is a very lightweight format - its syntax is limited to a minimum, it is a trivially simple textual format, in which, apart from the data itself, only a few other constraints are used, such as comma or parenthesis. Due to such minimalism it is, unfortunately, a little less readable for humans than for example XML, but it makes up for it in small size, because it has no elements such as tags in XML. It's worth knowing JSON, because it's very useful for data exchange, especially in the network. In this article we'll discuss basic things like syntax, and in the next articles we'll see how to work on data from JSON in PHP and Javascript.

A brief description of the syntax

  • only double quotes are allowed - ",
  • field names must also be in quotation marks,
  • the last value must not be followed by a comma
  • A JSON can occur as an object or an array and contains several available data types: object, array, string, numbers, boolean (true or false), null

Example of JSON:

    "name": "Tom",
    "age": 37,
    "isActive": true,
    "address": {
        "city": "London",
        "street": "Ramillies Rd"
    "hobbies": ["swimming", "jogging", "football"]

How to use the JSON Formatter & Validator online?

The JSON you have can be formatted in a way that is unreadable to humans (e.g. does not contain any newline characters or indentations). In this case it is worth using our tool. Just paste or type the JSON you have in the text field. Then click the 1st button from menu or button to format JSON data Format with proper indentation and line feeds. If JSON has an error, you will be informed about it. If you want to copy a formatted JSON to the clipboard, just use the button.