dynobase-icon
Dynobase

Question: Can DynamoDB have nested objects?

Rafal Wilinski

Answered by Rafal Wilinski

Last updated: October 23rd, 2026

Answer

Yes. DynamoDB stores nested objects as Maps and nested arrays as Lists, with up to 32 levels of document nesting. All nested values count toward the complete item's 400 KB limit.

For example, an item can contain profile: { address: { city: "Seattle" } }. A document client stores that structure directly; do not call JSON.stringify unless you intentionally want an opaque string.

Use document paths in projections, conditions and updates. An update such as SET #p.#a.#c = :city can change the nested city when the parent maps exist. Map each alias to its attribute name. DynamoDB cannot automatically create a missing parent map from an update to one of its children, so initialize the structure first or write the complete parent map.

Nested fields are not eligible as index-key paths. If you frequently query by city, maintain a top-level scalar attribute such as cityKey and build the appropriate GSI. A filter on profile.address.city still reads items before filtering them.

Split independently growing collections into separate items when they would make the parent document large or create write contention. See JSON path filtering and GSI design.

Source: AWS document types.

Dynobase is a Professional GUI Client for DynamoDB

Start your 7-day free trial today

Product Features

Download
/
Pricing
/
Member Portal
/
Privacy
/
EULA
/
Twitter
© 2026 Dynobase
+
Still using AWS DynamoDB Console?
Try Dynobase to accelerate your DynamoDB workflow. Start your 7-day free trial today.