Fundamentals

You model DynamoDB like a spreadsheet with columns, then discover there is no schema, no ALTER TABLE, and the primary key is the address on disk. Every access pattern you sketch later either fits that address or fights it.

This section is the typed-value model, how items group into collections under one partition key, and why consistency choices show up on every read API. SQL habits die here: attributes are optional per item, types matter at the API boundary, and a composite key is not metadata — it is the physical sort order of your data.

What you can do after

  • Read any DynamoDB item and name each attribute's type without guessing from JSON.
  • Explain why a Query returns one item collection and what partition key + sort key actually control on disk.
  • Size an item before you denormalize and know when a 400 KB hard limit will reject the write.
  • Pick strong vs eventual consistency for a read and predict what stale data costs in your UI.

Reading order

Work through the guides in this order. Each step assumes the previous one.

  1. When to use DynamoDB — the fit/no-fit decision before you commit storage and migration cost to a key-value design.
  2. Data typesS, N, B, sets, lists, and maps; the type tags every API call must respect.
  3. JSON marshalling — how plain JSON becomes typed DynamoDB attributes and where silent coercion bites.
  4. Item size limit — the 400 KB cap, what counts toward it, and patterns that blow past it when you pack children inline.
  5. Item-based actions — every operation targets whole items; partial updates are expressions, not column writes.
  6. Item collections — all items sharing a partition key; the unit a single Query can walk in sort order.
  7. Composite primary key — partition + sort key as physical layout; why "primary key" in DynamoDB is a range, not a scalar.
  8. Consistency — strong vs eventual on the base table; what you can and cannot ask for on a GSI.
0 of 10 readQuiz
When to Use DynamoDB (and When Not To)
When to use DynamoDB and when not to. The access-pattern, scale and cost signals that favor it over a relational database, and its wrong-fit workloads.
Beginner10 min read
DynamoDB Data Types: Every Type, with Examples
DynamoDB's ten data types — scalars (S, N, B, BOOL, NULL), documents (M, L) and sets (SS, NS, BS), how they look in DynamoDB-JSON, and which can be a key.
Beginner6 min read
DynamoDB JSON & Marshalling
DynamoDB JSON and marshalling — why every value is wrapped in a type tag, how the format differs from plain JSON, and how to convert between the two.
Beginner6 min read
The DynamoDB Item Size Limit (400 KB)
The DynamoDB 400 KB item size limit — what counts toward it, how attribute names and nesting add up, and how to model around unbounded item growth.
Beginner5 min read
DynamoDB Limits and Quotas, Verified on the Live Service
Every DynamoDB limit and quota, with the verbatim error the live service returns when you cross it — item size, key sizes, batches, transactions, indexes.
Intermediate10 min read
DynamoDB Item-Based Actions
DynamoDB item-based actions — GetItem, PutItem, UpdateItem and DeleteItem each address one item by its full primary key, and differ from Query and Scan.
Beginner7 min read
DynamoDB Item Collections
What a DynamoDB item collection is — every item sharing a partition key — why it's the unit of efficient Query reads, and the limits to watch out for.
Beginner8 min read
DynamoDB Composite Primary Key: Partition + Sort Key
A DynamoDB composite primary key is a partition key plus a sort key — it groups related items together and unlocks range queries a simple key can't do.
Beginner7 min read
DynamoDB Strongly vs Eventually Consistent Reads
DynamoDB strongly consistent vs eventually consistent reads — what each guarantees, the 2× RCU cost of ConsistentRead, and why a GSI is eventual-only.
Intermediate7 min read
Knowledge checkTake the quiz
Check what you’ve learned in this section.

A composite key on USER#123 with sort keys PROFILE, ORDER#… lets one Query return a user's profile and recent orders sorted by time. Misunderstand item collections and you either Scan the table or fetch each row with GetItem — both scale poorly and both show up on the bill.

Hands-on in DynoTable

Open a live table in DynoTable and inspect keys in the grid. The table's Overview shows partition and sort key names plus every GSI so you can see how items group before you write a query. Paste a sample item into the free item size calculator to measure bytes toward the 400 KB limit; denormalizing three child records often crosses the 1 KB line where read and write capacity units start rounding up.

The visual filter builder adds hash and range key conditions with type-aware operators, so you practice Query against a real collection instead of hand-writing JSON. Free read-only access covers queries, PartiQL SELECT, and exports; writes require a paid trial or license.

Download DynoTable and run these primitives against your own tables as you read.