Conversion methods for JSON could be divided into two large groups. First group is a conversion of the format itself which preserves the structure of the source JSON. Second group is conversion with a change of structure when certain JSON structures are transformed, modified or removed during conversion.
Format conversion of JSON is quite straightforward when target format has similar capabilities as JSON. This includes conversions to YAML, BSON, MessagePack and XML. All of these formats support all of the JSON features and it is possible to perform 1:1 conversion. There could be certain minor exclusions and limitations with numberic values, nulls, and variables length which need to be addressed during conversion.
Below are some of the JSON format convertors.
When JSON needs to be converted to a format which is different in principle then not only format but also structure conversion is required. For example, conversion from JSON to CSV is possible but JSON will need to be transformed during conversion. Also, certain JSON elements may have to be skipped. This happens because JSON is a tree like format with multiple nesting levels and children elements. CSV is a two-dimensional table with headers. That is why unless JSON was specifically prepared or designed to handle that kind of conversion it will be impossible to preserve all data in JSON the way it is.
A good starting website for JSON structure conversion is http://www.convertcsv.com/json-to-csv.htm. There you can conversion correctly structured JSON to CSV with various structural transformations applied. Click on “Examples” buttons under the input edit box to check acceptable JSON formatting and then click on “Convert JSON to CSV” to check resulting CSV file.
File Extension Info | |
---|---|
JavaScript Object Notation | |
MIME TYPE | |
application/json | |
JSON File Opens With | |