Roadmap
64 topics in 10 tracks, then 19 case studies. Read the stages in order. Inside a stage, read the core topics first.
How to use this roadmap
- Read one topic at a time. Do each walkthrough and each estimate yourself before you read the answer.
- Do the quiz at the end. Your score sets the date of your next revision. The site saves it in this browser.
- Revise when a topic is due. Due topics show a mark below. A short revision now saves a long one later.
- After each stage, do its case studies. A case study uses the topics of the stage in one complete design.
0 of 64 started
6 topics are ready to read. Nothing is due for revision.
Show
- Ready
- Done
- Due
- Planned
- 1
Foundations
Start here
How to approach a design, the numbers that decide it, and what "scalable" and "available" mean in numbers.
- 1.How to approach a system design problemCore20 minReady to read
- 2.Numbers every engineer should knowCoreGo build25 minReady to read
- 3.Back-of-envelope estimationCore30 minReady to read
- 4.Performance vs scalability, scaling up vs scaling outCore25 minReady to read
- 5.Availability in numbers: nines, SLOs, error budgetsCore30 minReady to read
Networking and communication
How a request travels, how services talk to each other, and how traffic is spread over servers.
- 6.How a request travels: DNS, TCP, TLS, HTTPCorePlanned
- 7.TCP vs UDP, and HTTP/1.1 vs HTTP/2 vs HTTP/3IntermediatePlanned
- 8.API styles: REST, gRPC, GraphQLCorePlanned
- 9.Load balancing: L4 vs L7, algorithms, health checksCoreGo buildPlanned
- 10.CDNs: push vs pull, edge cachingCorePlanned
- 11.API gateways, backends-for-frontends, service discoveryIntermediatePlanned
- 12.Real-time delivery: polling, WebSockets, server-sent eventsIntermediatePlanned
Then design
- URL shortener
- 2
Data
Storage and databases
Data models, how storage engines work inside, transactions, and the special stores for blobs, search and time series.
- 13.Choosing a data model: relational, key-value, document, wide-column, graphCorePlanned
- 14.How indexes work: B-treesIntermediateGo buildPlanned
- 15.LSM-trees, SSTables and compactionIntermediateGo buildPlanned
- 16.Write-ahead logs, fsync and crash recoveryIntermediateGo buildPlanned
- 17.Transactions and isolation levelsIntermediatePlanned
- 18.Query performance: tuning, denormalization, materialized viewsIntermediatePlanned
- 19.Object storage: blobs, metadata, erasure codingIntermediatePlanned
- 20.Search: inverted indexesIntermediatePlanned
- 21.Time-series dataAdvancedPlanned
- 22.Probabilistic data structures: Bloom filters, HyperLogLog, count-min sketchIntermediateGo buildPlanned
- 23.Geospatial indexing: geohash, quadtrees, S2IntermediatePlanned
Caching
Where to put a cache, how to keep it correct, and what happens when one key gets all the traffic.
- 38.Cache strategies: cache-aside, read-through, write-through, write-behind, refresh-aheadCorePlanned
- 39.Where to cache: client, CDN, web server, application, databaseCorePlanned
- 40.Eviction and invalidation: LRU, LFU, TTLCoreGo buildPlanned
- 41.Hot keys, stampedes and request coalescingIntermediatePlanned
Then design
- Rate limiter
- Unique ID generator
- Distributed cache
- Search autocomplete
- 3
Distribution
Replication and partitioning
Copies of data for safety and speed, and splitting data so that it fits on many machines.
- 24.Leader–follower replication: lag, failoverCorePlanned
- 25.Multi-leader and leaderless replication: quorums, read repair, hinted handoffIntermediatePlanned
- 26.Partitioning: by range vs by hash, hot spots, rebalancingCorePlanned
- 27.Consistent hashingCoreGo buildLive demo25 minReady to read
- 28.Rendezvous hashing, Jump hash and MaglevAdvancedPlanned
- 29.Request routing and secondary indexes across partitionsIntermediatePlanned
Then design
- Key-value store (Dynamo-style)
- 4
Agreement
Consistency and consensus
What "consistent" means, how machines agree on order and on a leader, and how transactions span services.
- 30.CAP and PACELCCorePlanned
- 31.Consistency models: linearizable, causal, eventual, read-your-writesIntermediatePlanned
- 32.Time and order: clock drift, Lamport clocks, vector clocks, HLCIntermediateLive demoPlanned
- 33.Resolving conflicts: last-write-wins, version vectors, CRDTsAdvancedGo buildPlanned
- 34.Consensus with RaftAdvancedGo buildLive demoPlanned
- 35.Leader election, leases and fencing tokensIntermediatePlanned
- 36.Distributed transactions: two-phase commit, sagas, compensationIntermediatePlanned
- 37.Coordination services: etcd and ZooKeeperIntermediatePlanned
Then design
- Distributed job scheduler
- 5
Async and failure
Messaging, streams and batch
Doing work later and elsewhere, delivery guarantees, logs, and processing data in large batches or as events arrive.
- 42.Why asynchronous: queues, task queues, background jobsCorePlanned
- 43.Delivery guarantees: at-most-once, at-least-once, exactly-once, and idempotencyCorePlanned
- 44.Logs vs queues: how Kafka worksIntermediateGo buildPlanned
- 45.Messaging patterns: pub/sub, competing consumers, priority queues, claim checkIntermediatePlanned
- 46.Batch processing: MapReduce and dataflowIntermediatePlanned
- 47.Stream processing: windows, watermarks, stateAdvancedPlanned
- 48.Change data capture and the outbox patternIntermediatePlanned
Reliability and operations
Failing well, protecting a service from overload, finding failures, and recovering from disasters.
- 49.Timeouts, retries, backoff with jitter, retry stormsCorePlanned
- 50.Circuit breakers and bulkheadsIntermediateGo buildPlanned
- 51.Rate limiting: token bucket, leaky bucket, sliding windowCoreGo buildLive demoPlanned
- 52.Back pressure and load sheddingIntermediatePlanned
- 53.Failure detection: heartbeats, phi accrual, gossip (SWIM)AdvancedGo buildPlanned
- 54.Observability: metrics, logs, traces, alertsCorePlanned
- 55.Performance antipatterns: chatty I/O, busy database, noisy neighbourIntermediatePlanned
- 56.Multi-region and disaster recovery: RPO, RTO, backups, active-activeIntermediatePlanned
Then design
- Notification system
- Web crawler
- Message queue (Kafka)
- Metrics and monitoring system
- 6
Architecture
Architecture patterns
How to divide a system into services, and the patterns that connect them.
- 57.Monolith vs microservices, and service boundariesCorePlanned
- 58.Event-driven architecture: choreography vs orchestrationIntermediatePlanned
- 59.CQRS and event sourcingIntermediatePlanned
- 60.Sidecar, ambassador and service meshIntermediatePlanned
- 61.Migrating safely: strangler fig, anti-corruption layerIntermediatePlanned
- 62.Async request–reply, pipes and filters, scheduler–agent–supervisorAdvancedPlanned
Security
Who the caller is, what they can do, and how services trust each other.
- 63.Authentication and authorization: sessions, tokens, OAuth2 and OIDCCorePlanned
- 64.Securing services: TLS and mTLS, signed URLs, gatekeeper, secretsIntermediatePlanned
Then design
- News feed
- Chat system
- Video streaming
- Ride sharing and nearby places
- Payment system
- 7
Capstones
Then design
- Object storage (S3)
- File sync (Dropbox)
- Capstone: backup and restore for Kubernetes
Interview fast track
If you have little time before an interview, read these 27 topics in this order. Then do the URL shortener, rate limiter, key-value store and news feed case studies.
- 1How to approach a system design problem
- 2Numbers every engineer should know
- 3Back-of-envelope estimation
- 4Performance vs scalability, scaling up vs scaling out
- 5Availability in numbers: nines, SLOs, error budgets
- 6How a request travels: DNS, TCP, TLS, HTTP
- 7API styles: REST, gRPC, GraphQL
- 8Load balancing: L4 vs L7, algorithms, health checks
- 9CDNs: push vs pull, edge caching
- 10Choosing a data model: relational, key-value, document, wide-column, graph
- 11Transactions and isolation levels
- 12Probabilistic data structures: Bloom filters, HyperLogLog, count-min sketch
- 13Geospatial indexing: geohash, quadtrees, S2
- 14Leader–follower replication: lag, failover
- 15Partitioning: by range vs by hash, hot spots, rebalancing
- 16Consistent hashing
- 17CAP and PACELC
- 18Distributed transactions: two-phase commit, sagas, compensation
- 19Cache strategies: cache-aside, read-through, write-through, write-behind, refresh-ahead
- 20Eviction and invalidation: LRU, LFU, TTL
- 21Why asynchronous: queues, task queues, background jobs
- 22Delivery guarantees: at-most-once, at-least-once, exactly-once, and idempotency
- 23Timeouts, retries, backoff with jitter, retry storms
- 24Rate limiting: token bucket, leaky bucket, sliding window
- 25Observability: metrics, logs, traces, alerts
- 26Monolith vs microservices, and service boundaries
- 27Authentication and authorization: sessions, tokens, OAuth2 and OIDC