1. Home
  2. Knowledge Base
  3. Java
  4. JSON – Comparison with XML

JSON – Comparison with XML

JSON and XML are human readable formats and are language independent. They both have support for creation, reading and decoding in real world situations. We can compare JSON with XML, based on the following factors −


XML is more verbose than JSON, so it is faster to write JSON for programmers.

Arrays Usage

XML is used to describe the structured data, which doesn’t include arrays whereas JSON include arrays.


JavaScript’s eval method parses JSON. When applied to JSON, eval returns the described object.


Individual examples of XML and JSON −


   "company": Volkswagen,
   "name": "Vento",
   "price": 800000



Was this article helpful?

Related Articles