Course contentsShow
← Cloud and Infrastructure
Lesson 2532 of 2,98954. Serverless ArchitecturesFree lesson

DynamoDB Capacity Modes

Compare on-demand and provisioned capacity modes, understanding cost implications and use cases for each.

DynamoDB Capacity Modes

What you'll learn: How to choose between DynamoDB's on-demand and provisioned capacity modes based on traffic patterns and cost requirements.

Understanding Capacity Modes

DynamoDB offers two ways to pay for and manage throughput: on-demand and provisioned capacity. Think of it like choosing between a taxi (on-demand) and a monthly parking pass (provisioned)—each suits different usage patterns.

On-Demand Capacity

On-demand mode automatically scales to accommodate your workload with no capacity planning. You pay per request, making it ideal for:

  • Unpredictable traffic patterns
  • New applications with unknown workloads
  • Spiky workloads with sudden peaks
  • Development and testing environments

Cost model: You pay for each read and write request—no minimum commitment. Simple to understand, but costs can escalate with high sustained usage.

Provisioned Capacity

Provisioned mode requires you to specify Read Capacity Units (RCUs) and Write Capacity Units (WCUs) in advance. Think of it as reserving bandwidth ahead of time. Best for:

  • Predictable traffic patterns
  • Steady-state workloads with consistent demand
  • Cost optimization when traffic is forecastable
  • Long-running production applications

Cost model: You pay for provisioned capacity per hour, regardless of usage. Auto-scaling can adjust capacity within configured bounds, providing flexibility while maintaining cost predictability.

Cost Implications

On-demand typically costs 2-5x more per request than provisioned capacity, but you avoid paying for unused capacity. Provisioned is economical when you can accurately forecast and utilize at least 25-30% of provisioned throughput consistently.

You can switch between modes once per 24 hours, allowing flexibility as your application matures.

Key Takeaway: Choose on-demand for unpredictable or variable workloads and provisioned capacity for steady, predictable traffic where cost optimization matters—leverage DynamoDB's mode-switching capability as your application's patterns become clearer.