Both JSON and XML are text-based human readable formats with support for creating, reading, and decoding in real world applications. Both are hierarchical and language-independent text notation for data-interchange. Despite the common traits, they differ