DynamoDB JSON converter
Last updated: October 23rd, 2026
Convert one JSON object to DynamoDB AttributeValue JSON, or paste a DynamoDB item into the right-hand field to decode it. Conversion runs in your browser. Maps and lists retain their structure; sets become arrays and binary values become base64 strings in plain JSON.
What is DynamoDB JSON?
DynamoDB JSON is the typed representation used by the low-level API, not a description of the database's internal storage format. Each attribute value is wrapped in a type descriptor, such as S for a string or N for a number. For instance, { "value": 3 } becomes { "value": { "N": "3" } }.
How to use the converter
- Paste one plain JSON object on the left to generate a DynamoDB item.
- Paste one DynamoDB item on the right to remove the type descriptors.
- Copy the output after checking any error message below the fields.
The left field also accepts object-literal syntax such as unquoted keys, single-quoted strings and trailing commas. It does not execute JavaScript: constructor calls such as new Set() are not accepted. To inspect a GetItem response or stream record, paste only its Item, NewImage or OldImage attribute map, not the full response envelope.
The ten DynamoDB data type descriptors
S- String."hello"becomes{ "S": "hello" }N- Number, sent as a string.3becomes{ "N": "3" }B- Binary, base64 encoded.the bytes for hibecomes{ "B": "aGk=" }BOOL- Boolean.truebecomes{ "BOOL": true }NULL- Null.nullbecomes{ "NULL": true }M- Map, an object.{ "a": 1 }becomes{ "M": { "a": { "N": "1" } } }L- List, an array.[1, "x"]becomes{ "L": [{ "N": "1" }, { "S": "x" }] }SS- String Set.a set of "a" and "b"becomes{ "SS": ["a", "b"] }NS- Number Set.a set of 1 and 2becomes{ "NS": ["1", "2"] }BS- Binary Set.a set of byte arraysbecomes{ "BS": ["aGk="] }
Things that catch people out
- Numbers travel as strings.
{ "N": "3" }is correct,{ "N": 3 }is not. AWS sends them this way "to maximize compatibility across languages and libraries", and DynamoDB still treats them as numbers for arithmetic. - Numbers can be positive, negative or zero, with up to 38 digits of precision. The positive range is
1E-130to9.99...E+125and the negative range mirrors it. Exceeding 38 digits raises an exception, and leading and trailing zeroes are trimmed. A JavaScript number cannot represent that whole range, so this tool shows such values rounded, with a warning, and refuses a number set whose members would round to the same value. Keep high-precision values as DynamoDB N strings or use a decimal-aware SDK for exact conversions. - Sets are not lists.
SS,NSandBShold unique, unordered values of a single type, and they cannot be empty. Plain JSON has no set type, so this tool shows them as arrays. Converting that array back gives you anL, not a set. Binary loses its type the same way:Bis shown as its base64 text, and converting back gives you anS. NULLtakes the valuetrue, which reads oddly.{ "NULL": true }means the attribute is null.- Binary is base64 encoded in JSON, so
BandScan look identical on the wire. The type key is the only thing that distinguishes them. - Empty strings and empty binary values are allowed, as long as the attribute is not a table or index key, and they are also allowed inside a set, list or map. What is not allowed is an empty set itself. Empty lists and maps are fine.
- Lists and maps can be nested within each other up to 32 levels deep.
For application code, JavaScript SDK v3 provides marshall and unmarshall in @aws-sdk/util-dynamodb. Its document client accepts native values directly. See the JavaScript examples and the AWS AttributeValue reference for the wire format.
Frequently Asked Questions
Is DynamoDB JSON the same as ordinary JSON?
Will a conversion preserve sets and binary types?
Why does the converter round a large number?
Can I paste a list of items or a complete AWS response?
Dynobase is a Professional GUI Client for DynamoDB
Start your 7-day free trial today
Product Features
DynamoDB Tools
- SSH GUI Client
- Chat With Cloud
- MongoDB GUI Client
- AWS Cost Monitoring
- DynamoDB Query Builder
- DynamoDB Code Examples
- DynamoDB Node.js Queries
- DynamoDB JSON Converter
- DynamoDB UUID Generator
- DynamoDB Local Admin GUI
- DynamoDB Pricing Calculator
- DynamoDB Single-Table Design
- Best DynamoDB GUI Clients
- Dynobase vs DynoTable