Question: Can DynamoDB store documents?

Answered by Rafal Wilinski
Last updated: October 23rd, 2026
Answer
Yes. DynamoDB stores JSON-like documents using native Map and List attributes; you do not need to flatten them or serialize them into strings. Each document is an item with the table's required primary-key attributes.
For example, an order can contain a shipping-address map, a list of line-item maps, a Boolean payment flag and a null delivery date. Other items in the table can have different attributes. With a document client, ordinary objects and arrays are converted to the appropriate DynamoDB types.
The complete item must fit within 400 KB, including attribute names and nested values. Documents can be nested up to 32 levels. For a large PDF, office document or other file, store the file in S3 and keep its object key and searchable metadata in DynamoDB.
You can read or update nested paths such as shipping.city without replacing the whole document. However, a nested field cannot directly be a secondary-index key: copy values needed for indexed lookups into top-level scalar attributes. Filters on nested values are evaluated after reading data.
See DynamoDB data types and the JSON converter for the difference between plain JSON and DynamoDB's typed wire format.
Source: AWS document types.
Other Common DynamoDB FAQ (with Answers)
- What is the maximum number of partitions in DynamoDB?
- Can DynamoDB have duplicates?
- How to access DynamoDB from EC2?
- How do you mock DynamoDB in a test?
- Why is DynamoDB better than MongoDB?
- Can QuickSight read DynamoDB?
- Is DynamoDB HIPAA compliant?
- Is a DynamoDB table Region-specific?
- Is DynamoDB open source?
- What are the key differences between DynamoDB and Elasticsearch?
- Can Django use DynamoDB?
- Can DynamoDB have null values?
- What are the differences between DynamoDB and MySQL?
- How do you enable CloudTrail for DynamoDB?
- What is an access pattern in DynamoDB?
Dynobase is a Professional GUI Client for DynamoDB
Start your 7-day free trial today