Learn
The core 21 system design concepts.
Each one explained plainly, with a live simulation or an interactive diagram where it actually helps, and what to say about it in an interview. Read them in order or jump around.
- 01
Horizontal scaling & load balancing
Add identical stateless servers behind a load balancer instead of buying one bigger machine.Live 3D - 02
Caching
Keep hot data in memory so repeated reads skip the database, and decide what happens when it goes stale.Live 3D - 03
Content delivery networks (CDN)
Serve static files from servers close to the user so your own servers only handle dynamic work.Live 3D - 04
Database replication
Copy the database to read replicas to scale reads and survive failures, at the cost of replication lag.Live 3D - 05
Message queues & pub/sub
Decouple producers from consumers so slow work happens in the background and bursts are absorbed.Live 3D - 06
Latency, throughput & p95
Why averages lie, why latency explodes near full utilization, and how to talk about p95 and p99.Live 3D - 07
Sharding (partitioning)
Split one dataset across many databases by a shard key when a single primary can no longer keep up.Diagram - 08
Consistent hashing
Map keys to servers so that adding or removing a server moves only a small share of the keys.Interactive - 09
CAP theorem & consistency models
During a network partition you must choose between answering (availability) and being correct (consistency).Interactive - 10
SQL vs NoSQL
Relational databases, key-value, document, wide-column and graph stores: what each is good at and when to pick it.Comparison - 11
Rate limiting
Cap how many requests a client can make so one user or bot cannot take the system down for everyone.Interactive - 12
Back-of-envelope estimation
Turn users and actions into requests per second, storage and bandwidth in two minutes, the way interviewers expect.Interactive - 13
API gateway
One front door for every client: routing, authentication, rate limits and response shaping in one place.Diagram - 14
Real-time: polling, SSE & WebSockets
How servers push updates to clients, from simple polling to persistent WebSocket connections, and what each costs.Comparison - 15
Unique ID generation
Create IDs that never collide across many servers, sort by time, and need no central coordinator.Interactive - 16
Idempotency
Make retries safe, so a request sent twice (because of a timeout) has the same effect as sending it once.Interactive - 17
Retries, timeouts & circuit breakers
Survive slow or failing dependencies without making the outage worse.Interactive - 18
Database indexes
Find rows without scanning the whole table, and why every index makes writes a little slower.Interactive - 19
Leader election & consensus
Get several machines to agree on one leader (and one truth) even when some of them fail.Diagram - 20
Multi-region architecture
Run in several parts of the world for lower latency and to survive a whole region going down.Diagram - 21
Bloom filters
A tiny structure that answers "definitely not present" or "probably present", saving expensive lookups.Interactive