how to parse json

JavaScript
var jsonPerson = '{"first_name":"billy", "age":23}';
var personObject = JSON.parse(jsonPerson); //parse json string into JS objectparse() to convert text into a JavaScript object: var obj = JSON. parse('{ "name":"John", "age":30, "city":"New York"}'); Make sure the text is written in JSON format, or else you will get a syntax error.

Source

Also in JavaScript: