Size a shard set from data volume, throughput and per-shard capacity.
Shard count is set by whichever constraint binds harder, capacity or throughput. Key skew must be included because the hottest shard determines whether the system copes, not the average. Choosing a shard key that distributes evenly matters more than shard count, because skew cannot be fixed by adding shards.
Database Sharding
Shards = max(data ÷ shard capacity, skewed writes ÷ shard write capacity)
Shards = max(data ÷ shard capacity, skewed writes ÷ shard write capacity) Shard count is set by whichever constraint binds harder, capacity or throughput. Key skew must be included because the hottest shard determines whether the system copes, not the average.
Choosing a shard key that distributes evenly matters more than shard count, because skew cannot be fixed by adding shards.
This calculator takes 5 inputs: Total data volume, Total writes per second, Data capacity per shard, Write capacity per shard, Expected key distribution skew. The pre-filled defaults are a realistic starting point — replace them with figures from your own environment for a result you can act on.