JavaScript object notation, but it is not JavaScript because its format is made to look like JavaScript, but it is not. It is used in every backend language and works for transferring data between the browser and the server. JOSN is text written in JavaScript object notation. Because APIs understand json format, it is commonly used in APIs. So, if the browser or client cannot connect directly to the server, it needs an API between the client and server, and this API uses or understands JSON. JSON primarily supports six data types:

1. String; 2. Number; 3. Boolean 4. Null, 5. Object, 6. Array;

It operates in key-value mode, similar to a dictionary, but as a string.

import json # import json by import keyword
p='{"name": "Nihal","lang":["Python", "Java"]}' # this the format of json because of ''.
blog = {'course name': 'python', 'fee': 15000}  # this is dictionary format which can be 
# converted to the json format
f = json.dumps(blog)
print(f)

Converting JSON to Python Objects

json.loads()
p = '{"name": "Nihal","lang":["Python", "Java"]}'
parse p:
y = json.loads(p)  # the result will be converted into a python dictionary
print(y) # it will convert into dictionary inside the list Writing and Reading JSON File