Skip to content
Back to Architecture Library
Storage & Databases

Sharding

Splitting a large database into smaller, faster pieces.

Misconceptions

  • •Sharding is the first thing you should do
  • •Cloud providers shard everything automatically

Trade-offs

  • •Scale vs. Operational Complexity
  • •Performance vs. Global Query Ease

The Mental Model

Sharding is a method for distributing data across multiple machines. It allows for horizontal scaling of the data layer but adds significant complexity to the application logic.

Interactive Simulation
Table_1
Table_2
Table_3
Table_4

Relational: Strict schema, joins, and ACID compliance. Best for complex queries.

Architecture Primitives v1.0

Architect's Tip

When scaling for sharding, always consider the impact on downstream dependencies like databases and message queues.