Question: Can you store lists in DynamoDB?

Answered by Rafal Wilinski
Last updated: October 23rd, 2026
Answer
Yes. DynamoDB supports a native List type, so you can store an array without converting it into a JSON string. Lists preserve order, allow duplicate values and can contain different supported data types, including maps and other lists.
With the JavaScript document client, an attribute such as tags: ["new", "sale"] becomes a List. In the low-level API, the same value is {"L":[{"S":"new"},{"S":"sale"}]}. An empty list is valid.
You can update a list element by its zero-based index or append with list_append. To append when the attribute might be missing, use an expression such as SET #items = list_append(if_not_exists(#items, :empty), :newItems). Supply an empty array and the new array through the document client's value placeholders.
Use a Set instead when membership must be unique and order is irrelevant. Sets must contain one supported scalar type and cannot be empty.
The list shares the item's 400 KB size budget. A continuously growing event history is usually better stored as separate items with a common partition key and distinct sort keys. See data types and sort keys.
Source: AWS list and set types.
Other Common DynamoDB FAQ (with Answers)
- Is DynamoDB a wide-column store?
- How do you store JSON on DynamoDB?
- How do you enable CloudTrail for DynamoDB?
- How do you store a graph in DynamoDB?
- Can you rename a DynamoDB table?
- Can DynamoDB store blob data?
- Are DynamoDB table names globally unique?
- Can I use a UUID as a DynamoDB partition key?
- Which programming language works best with DynamoDB?
- Can Power BI connect to DynamoDB?
- Can Django use DynamoDB?
- How do you access DynamoDB from an Android app?
- Is DynamoDB open source?
- How do you parallelize requests in DynamoDB?
- How to track changes to items in DynamoDB?
Dynobase is a Professional GUI Client for DynamoDB
Start your 7-day free trial today