What is JSON to Amazon Ion Converter?
Amazon Ion is a richly-typed, self-describing data serialization format developed by Amazon that extends JSON with additional types and annotations. While JSON treats all numbers as a single type, Ion distinguishes between integers, decimals, and floats. Ion adds typed nulls (null.string, null.int), timestamps with timezone awareness, binary large objects (blobs and clobs), and type annotations that attach metadata directly to values. Ion text format is a strict superset of JSON — every valid JSON document is also valid Ion. Amazon QLDB uses Ion as its native document format, and DynamoDB's PartiQL queries operate on Ion data. This converter transforms your JSON into Ion text notation, with optional type annotations that make the Ion type system explicit for downstream processors.
How to Use
- Paste your JSON data into the input area on the left
- Toggle pretty print for human-readable output or compact mode for minimal size
- Enable type annotations to add explicit Ion type markers (string::, int::, decimal::, bool::, list::, struct::)
- Click "Convert" to generate the Ion text representation
- Copy the output and use it in your AWS QLDB queries, DynamoDB operations, or Ion-based pipelines
Why Use This Tool?
Tips & Best Practices
- All valid JSON is also valid Ion — Ion text is a strict superset of the JSON grammar
- Ion distinguishes between integers (1) and decimals (1.0), unlike JSON where all numbers share the same type
- Use type annotations when you need explicit type information for downstream Ion processors or schema validation
- For AWS QLDB PartiQL queries, Ion text format is the standard document representation for inserts and queries
- When converting back from Ion to JSON, Ion-specific types like timestamps and blobs are lost since JSON has no equivalent
Frequently Asked Questions
How are JSON types mapped to Ion types?
JSON strings become Ion strings, whole numbers become Ion ints (no decimal point), fractional numbers become Ion decimals, booleans become Ion booleans, null becomes Ion null, arrays become Ion lists, and objects become Ion structs. The key difference is that Ion preserves the integer vs. decimal distinction that JSON erases.
When should I NOT use Ion format?
Avoid Ion when your consumers do not support Ion parsing — most public APIs and third-party integrations expect JSON. Ion is best suited for AWS-internal communication, QLDB documents, and systems that have Ion libraries available. If human readability and universal compatibility matter more than type precision, stick with JSON.
What is Amazon Ion?
Amazon Ion is a richly-typed, self-describing data format developed by Amazon. It is a superset of JSON that adds typed nulls (null.string, null.int), timestamps, binary large objects (blobs/clobs), annotations (type::value), and S-expressions. Ion is used by AWS services like QLDB and DynamoDB for efficient data serialization.
How does Ion differ from JSON?
Ion extends JSON with typed nulls (null.string, null.int), timestamps, binary large objects (blobs/clobs), annotations (type::value), and S-expressions. Ion text format is a superset of JSON, meaning all valid JSON is also valid Ion. The most practical difference is Ion's ability to distinguish integers from decimals and its annotation system.
Can I use this with AWS QLDB?
Yes! The generated Ion text format is compatible with Amazon QLDB. QLDB uses Ion as its native data format for PartiQL queries and document storage. You can paste the converted Ion directly into QLDB console queries or use it with the QLDB driver in your application code.
Is my data sent to a server?
No, all processing happens entirely in your browser. Your JSON data never leaves your device. No data is collected, logged, or transmitted to any server, making this safe for converting sensitive AWS configurations and document data.
Real-world Examples
QLDB document insertion
Convert a JSON vehicle registration record into Ion text for insertion into an Amazon QLDB ledger via PartiQL.
{
"VIN": "1HGBH41JXMN109186",
"make": "Honda",
"model": "Civic",
"year": 2021,
"registered": true
}{
VIN: "1HGBH41JXMN109186",
make: "Honda",
model: "Civic",
year: 2021,
registered: true
}Ion with type annotations for schema validation
Generate Ion text with explicit type annotations for a system that requires strict type metadata on each field.
{
"orderId": 1001,
"total": 59.99,
"items": ["widget", "gadget"]
}{
orderId: int::1001,
total: decimal::59.99,
items: list::[
string::"widget",
string::"gadget"
]
}