JSON (JavaScript Object Notation) is a lightweight data-interchange format. It is easy for humans to read and write, and It is easy for machines to parse and generate. On this website you can find multiple JSON example, JSON formatter and beautifier to help you understand how to make a good JSON.
When exchanging data between a browser and a server, the data can only be text. JSON is text, and we can convert any JavaScript object into JSON, therefore send JSON to the server. See more information on Wikipedia.
Syntax
JSON data is written as name/value pairs. A name/value pair consists of a field name (in double quotes), followed by a colon, followed by a value. See next JSON example:
{ "key":"value" }
See the entire explanation on the Syntax & Examples page.
What is the difference between JSON and XML?
Before, XML (extensible markup language) was the only choice for open data interchange. But over the years JSON appeared. Therefore JSON has become a popular alternative to XML for multiple reasons.
See the entire explanation on the JSON vs XML page.