Breaking News
Home / ServerSide / What are the benefits of using JSON over XML?

What are the benefits of using JSON over XML?

JSON Benefits compared to XMLJSON and XML both can be used to marshall or unmarshal data in a Ajax request. However each has it own benefits particularly JSON. The following are the benefits.

 

Less Verbose, yet easy to debug (readable)

Readability of data over the wire is very much important to debug with ease. XML is very good at this, however XML requires two tags per data point, plus extra tags for the root nodes, this adds to size of the document. On the other hand JSON requires only one tag i.e. the name of the elements as such its less verbose. And the good part is that all this comes with sacrificing the readability.

More Speed & Less Bandwidth Utilization

Since the packet size is smaller in JSON compared to XML to convey the same data, the the data transmission between the Client and Server is faster using in turns helps to reduce network traffic as less number of bytes flow over the wire making the Server to get done quickly and the Client be more responsive.

Less Memory Footprint, faster generation & processing

The data structure for JSON is smaller resulting in less memory utilization on both Client and Server esp. at the Client Size, helping the browser to accept larger size JSON documents and parse them quickly with using much of Clients CPU and Memory making the Browser interface more responsive.

Supported in Browsers via Javascript

The other important benefit is you can parse JSON text with JavaScript’s eval() function. No special libraries are needed and this works across all the browsers so one don’t have to worry about cross-browser issues. As long as the browser has JavaScript enabled and support this eval() function, you will be able to parse JSON data.[pb_builder]

Check Also

What webservices standards are supported by Siebel Business Applications?

The following Web services standards are supported by Siebel Business Applications:     * Web Services …

Advertisment ad adsense adlogger