Skip to content
Free course · 192 lessons

System Design

From one server to planet-scale systems.

A complete path through high-level design: the networking and database basics everything rests on, the building blocks you combine, the distributed-systems theory behind them, and 61 worked case studies that put it all together.

Learning path

5 stages, one step at a time

Each stage builds on the one before it. Go in order the first time, then jump around when you need a refresher.

  1. 01

    Foundations

    Vocabulary and the basics every later lesson assumes.

    12 lessons · 3.2 hrsJump to stage →
  2. 02

    Building blocks

    The components you assemble into real systems.

    21 lessons · 5 hrsJump to stage →
  3. 03

    Theory and data

    Why distributed systems behave the way they do, and where data lives.

    21 lessons · 5.7 hrsJump to stage →
  4. 04

    Architecture and operations

    Shaping systems, then keeping them reliable and secure.

    32 lessons · 8.5 hrsJump to stage →
  5. 05

    Applied design

    End-to-end designs, AI systems, and interview practice.

    106 lessons · 27 hrsJump to stage →
Curriculum

13 parts · 192 lessons

Open a part to see its lessons. Completed lessons are ticked off as you go.

Stage 1 Foundations

00PrerequisitesNetworking, operating systems, data structures, databases and APIs, in just enough depth.5 lessons1.3 hrs5
  1. 01Networking Fundamentals for System DesignWhere the first 300 ms of a connection go, and how to choose between TCP and UDP, the HTTP versions, DNS settings, TLS options and real-time transports.18m✓
  2. 02Operating System Essentials for System DesignProcesses, threads, memory hierarchy with real latency numbers, I/O models (epoll, kqueue, io_uring), and file system internals you need to design systems.13m✓
  3. 03Data Structures for Distributed SystemsThe handful of data structures that power modern infrastructure: hash tables, B-trees, LSM-trees, Bloom filters, skip lists, and consistent hashing rings.14m✓
  4. 04Database Fundamentals for System DesignSQL, ACID, indexing, query execution, and the normalization vs denormalization debate, covered at the depth you need to design real systems.16m✓
  5. 05API Design Basics: REST, GraphQL, gRPC, and the Hard PartsResource modeling, GraphQL's N+1 problem, gRPC streaming, versioning strategies, idempotency keys, and cursor pagination done right.17m✓
01Core FundamentalsScalability, latency, availability, consistency and quick estimation.7 lessons1.9 hrs52
  1. 01Scalability: Growing a System Without Breaking ItVertical vs horizontal scaling, stateless services, read vs write scaling, and when scaling is the wrong answer. The vocabulary every system design conversation uses.17m✓
  2. 02Latency and Throughput: The Two Numbers That MatterLatency vs throughput, Jeff Dean's numbers, tail latency (p50/p95/p99), Little's Law, and how to find the real bottleneck in any system.19m✓
  3. 03Availability and Reliability: Nines, SLOs, and Staying UpAvailability math, MTBF/MTTR, redundancy patterns, SLI/SLO/SLA, error budgets, dependency math, and real-world outage lessons.17m✓
  4. 04Consistency Models: What Readers Actually SeeStrong, eventual, and causal consistency. Read-your-writes, monotonic reads, and the client-centric vs data-centric distinction that makes consistency tractable.16m✓
  5. 05Back-of-the-Envelope EstimationPowers of 2 and 10, storage and bandwidth templates, QPS math, and worked examples for Twitter and YouTube scale. The interview skill that matters in production too.15m✓
  6. 06How to Approach a System Design QuestionA repeatable 6-step framework for 45-minute system design interviews: clarify, estimate, API, high-level design, deep dive, trade-offs. Minute-by-minute plan with company-specific flavors.16m✓
  7. 07Trade-off ThinkingEvery design decision is a trade-off. How to articulate, structure, and defend your choices, and how to recognize when not choosing is the right move.16m✓

Stage 2 Building blocks

02Building BlocksLoad balancers, DNS, caches, queues, CDNs, databases, sharding and more.21 lessons5 hrs1164
  1. 01Load Balancers: Spreading Traffic, Absorbing FailureL4 vs L7 load balancing, algorithms, health checks, and how Envoy, HAProxy, NGINX, and AWS ALB/NLB actually work in production.17m✓
  2. 02Reverse Proxies and API Gateways: The Smart EdgeTLS termination, routing, auth, rate limiting, and why an API gateway is more than a smarter load balancer.18m✓
  3. 03Content Delivery Networks: Moving Bytes Closer to UsersHow CDNs work, edge caching, cache keys and invalidation, and how Cloudflare, Akamai, and Fastly differ in practice.19m✓
  4. 04Caching: From Browser to DatabaseCache hierarchy, five write patterns, eviction policies (LRU/TinyLFU), stampede prevention, and why invalidation is the hardest problem in distributed systems.18m✓
  5. 05SQL Databases: The Boring Technology That WinsB-trees, MVCC, isolation levels, indexing, and why PostgreSQL and MySQL are still the right answer for most systems.17m✓
  6. 06NoSQL Databases: Picking the Right Non-Relational ToolKey-value, document, wide-column, and graph stores, and how DynamoDB, Cassandra, MongoDB, and Neo4j differ in practice.16m✓
  7. 07Database Partitioning and Sharding: When One Node Is Not EnoughRange, hash, and consistent-hash partitioning, hot spots, resharding, and how Notion, Figma, and Discord partition data in practice.17m✓
  8. 08Database Replication: Keeping Copies in SyncLeader-follower, multi-leader, and leaderless replication, sync vs async, failover, and how Postgres, MySQL, Cassandra, and DynamoDB differ.16m✓
  9. 09Message Queues and Streaming: Decoupling at ScaleQueues vs logs, Kafka vs RabbitMQ vs SQS, delivery semantics, partitioning, consumer groups, and when streaming beats request-response.15m✓
  10. 10Pub/Sub: Fan-Out and Event-Driven SystemsTopics, subscriptions, fan-out strategies, and how Google Pub/Sub, Redis, NATS, and SNS+SQS implement publish/subscribe at scale.16m✓
  11. 11Real-Time Communication: WebSockets, SSE, and Long PollingLong polling, Server-Sent Events, WebSockets, WebRTC, and MQTT: when to use each, how to scale persistent connections, and production lessons from Discord and Slack.17m✓
  12. 12Rate Limiting: Protecting Systems from ThemselvesToken bucket, leaky bucket, fixed and sliding windows, distributed rate limiting, and how Stripe, Cloudflare, and GitHub protect their APIs.17m✓
  13. 13Service Discovery and Service Mesh: Finding and Talking to ServicesDNS, client-side and server-side discovery, health checks, sidecars, mTLS, and what Consul, Envoy, Istio, and Linkerd actually solve.16m✓
  14. 14Blob and Object Storage: Storing the Big StuffS3 semantics, object storage internals, multipart uploads, lifecycle policies, and when to pick S3 vs GCS vs MinIO vs a filesystem.16m✓
  15. 15Geospatial Indexing: Geohash, Quadtree, R-tree, S2, and H3Space-filling curves, hierarchical grids, and tree indexes for location queries - with decision guidance on geohash vs quadtree vs R-tree vs S2 vs H3.14m✓
  16. 16Edge Computing (Cloudflare Workers, Lambda@Edge, Deno Deploy)Design applications for the edge: cold starts, state replication with Durable Objects, edge databases, and the limits of running code close to users.16m✓
  17. 17DNS as a Traffic Router: Records, TTLs and Routing PoliciesUse DNS to steer users: the records that matter, how TTLs limit failover, and when to use weighted, latency and geolocation routing.6m✓
  18. 18Task Queues: Running Work in the BackgroundMove slow work out of the request path with task queues: workers, retries, idempotency, scheduling and back pressure.6m✓
  19. 19Database Federation: Splitting Databases by FunctionFederation moves each business function to its own database. When it beats sharding, what it costs you, and how to migrate safely.6m✓
  20. 20SQL Tuning: Finding and Fixing Slow QueriesA practical workflow for database performance: profile first, then fix schemas, indexes, joins, pagination and hot tables.8m✓
  21. 21What to Cache: Query Results vs ObjectsChoose what your application caches: rows, query results, assembled objects or rendered pages, and why objects are usually easier to invalidate.7m✓

Stage 3 Theory and data

03Distributed Systems TheoryConsensus, quorums, clocks, CRDTs and distributed transactions.11 lessons3 hrs65
  1. 01Consensus Protocols: How Distributed Systems AgreeRaft and Multi-Paxos explained: leader election, log replication, safety under term numbers, and why etcd, Consul, and CockroachDB picked Raft.17m✓
  2. 02Consistency Deep Dive: Linearizability, Serializability, and the Spectrum BetweenLinearizability vs serializability vs causal vs eventual, external consistency, and how to reason precisely about what your database actually gives you.17m✓
  3. 03Quorums and Replication: The Math of R + W > NRead and write quorums, Dynamo-style replication, sloppy quorums, hinted handoff, and when quorums give you linearizability (and when they do not).16m✓
  4. 04CAP and PACELC: The Tradeoff That Keeps Confusing PeopleWhat CAP actually says (and what it doesn't), the three big misconceptions, and how PACELC fixes the omission of latency.16m✓
  5. 05Clocks and Ordering: Lamport, Vector, and Hybrid Logical ClocksWhy wall-clock time lies, happens-before, Lamport clocks, vector clocks, hybrid logical clocks, and Google TrueTime.18m✓
  6. 06CRDTs: Conflict-Free Replicated Data TypesState-based (CvRDT) and op-based (CmRDT) CRDTs, G-Counter, PN-Counter, OR-Set, LWW-Register, and how Yjs, Automerge, Figma, and Redis use them.16m✓
  7. 07Distributed Transactions: 2PC, Saga, and When to Avoid BothTwo-phase commit, Percolator, Sagas, outbox pattern, and the honest answer to distributed transactions: don't, or pay the price.18m✓
  8. 08Idempotency and Exactly-Once: The Honest Truth About Delivery GuaranteesWhy exactly-once delivery is a myth, how idempotency keys make at-least-once feel exactly-once, and how Stripe and Kafka implement it.17m✓
  9. 09Failure Detection: Deciding a Node Is DeadHeartbeats, phi-accrual detectors, gossip (SWIM), and why 'is it dead or just slow?' has no correct answer.17m✓
  10. 10Consistent Hashing: Keys to Nodes Without Global ReshufflesThe hash ring, virtual nodes, bounded-load variant, rendezvous hashing, Maglev, and jump hash for distributing keys across dynamic node sets.15m✓
  11. 11Merkle Trees and Anti-Entropy: Keeping Replicas in Sync CheaplyMerkle trees, anti-entropy protocols, read repair, hinted handoff, and how Dynamo, Cassandra, and Git use hashed trees to find the differences.16m✓
04Data SystemsStorage engines, analytics, streaming, search and specialized databases.10 lessons2.6 hrs82
  1. 01Storage Engines: B-Trees, LSM-Trees, and Why Your Database Feels the Way It DoesHow B-tree and LSM-tree storage engines shape read, write, and space amplification, with examples from InnoDB, PostgreSQL, RocksDB, and Cassandra.16m✓
  2. 02OLTP vs OLAP: Row Stores, Column Stores, and Matching Shape to WorkloadWhy transactional systems use row-oriented storage and analytical systems use columnar, with examples from Postgres, MySQL, Redshift, BigQuery, ClickHouse, and Snowflake.16m✓
  3. 03Data Warehouses and Data Lakes: Structure, Schema, and the LakehouseHow Redshift, BigQuery, Snowflake, S3-based lakes, and the lakehouse pattern with Delta Lake, Iceberg, and Hudi actually fit together.16m✓
  4. 04Stream vs Batch Processing: Lambda, Kappa, and the End of That DebateBatch with Spark and Hadoop, streaming with Kafka Streams, Flink, and Spark Streaming, and how Lambda and Kappa architectures stack up.15m✓
  5. 05Change Data Capture: Streaming the Database's Inner MonologueHow Debezium, Maxwell, and the outbox pattern turn WAL and binlog entries into reliable event streams, and when each approach is the right call.16m✓
  6. 06Search Systems: Inverted Indexes, BM25, and Running Elasticsearch in ProductionHow Elasticsearch, OpenSearch, and Solr build inverted indexes, score with BM25, and handle faceting, relevance tuning, and sharding at scale.18m✓
  7. 07Time-Series Databases: Metrics, Events, and Retention at ScaleHow Prometheus, InfluxDB, TimescaleDB, and VictoriaMetrics handle write-heavy time-series workloads with downsampling and retention policies.15m✓
  8. 08Graph Databases: Property Graphs, Cypher, and When Joins Are the ProblemHow Neo4j, Amazon Neptune, and Dgraph model relationships, and when graph queries beat recursive SQL joins.16m✓
  9. 09Vector Databases: Embeddings, ANN Indexes, and the Retrieval Layer for AIHow Pinecone, Weaviate, Milvus, and pgvector store and search embeddings using HNSW and IVF approximate nearest neighbor indexes.15m✓
  10. 10Key-Value Stores: Redis, Memcached, DynamoDB, and Picking the Right Hash TableHow Redis, Memcached, and DynamoDB differ in durability, data model, and scaling, and when each is the right key-value store.16m✓

Stage 4 Architecture and operations

05Architecture PatternsMonoliths, microservices, events, CQRS, multi-region and multi-tenant designs.11 lessons2.9 hrs83
  1. 01Monolith vs Microservices: Team Topology, Conway's Law, and the Distributed System TaxWhen a modular monolith beats microservices, how Conway's Law shapes architecture, and what the distributed system tax actually costs you.16m✓
  2. 02Event-Driven Architecture: Notifications, State Transfer, and ChoreographyThe three flavors of events, how Kafka and event buses enable loose coupling, and when choreography beats orchestration.17m✓
  3. 03CQRS: Separating Reads from Writes Without Losing Your MindCommand Query Responsibility Segregation in practice: when to split read and write models, how to handle eventual consistency, and when CQRS is overkill.14m✓
  4. 04Event Sourcing: Events as the Source of TruthStoring state as an append-only log of events, with replay, projections, snapshots, and the ops reality of running event-sourced systems.16m✓
  5. 05Serverless: Functions, Cold Starts, and When FaaS Actually Saves MoneyAWS Lambda, Google Cloud Functions, and Azure Functions in practice: cold starts, concurrency models, and the honest economics of serverless.14m✓
  6. 06Backend for Frontend: Per-Client API Aggregation Done RightWhen one API cannot serve web, mobile, and partner clients well, the BFF pattern gives each client its own aggregation layer.14m✓
  7. 07Strangler Fig: Incremental Migration Without a Big BangMartin Fowler's strangler fig pattern for replacing legacy systems incrementally, with routing, facades, and how teams actually execute multi-year migrations.19m✓
  8. 08Hexagonal and Clean Architecture: Keeping Business Logic IndependentPorts and adapters, clean architecture, and onion architecture: how to keep domain logic testable and framework-independent.15m✓
  9. 09Multi-Region Architecture: Active-Passive, Active-Active, and CRDTsDesigning systems that survive regional failure: DNS failover, active-passive replication, active-active with CRDTs, and Cloudflare's model.17m✓
  10. 10Multi-Tenancy: Silo, Pool, and the SaaS Isolation SpectrumDesigning SaaS platforms that host many tenants on shared infrastructure: isolation levels, noisy-neighbor defenses, per-tenant metering, and when to graduate a whale.15m✓
  11. 11CRDT Applications (Yjs, Automerge, Local-First Software)Design local-first collaborative software with CRDTs: Yjs, Automerge, peer-to-peer sync, and the architectural shift away from authoritative central servers.16m✓
06Reliability & OperationsObservability, SLOs, resilience, deployments, incidents and cost.11 lessons2.9 hrs83
  1. 01Observability: Metrics, Logs, Traces, and the OpenTelemetry StandardThe three pillars of observability, USE vs RED methods, and how OpenTelemetry, Prometheus, Grafana, and Jaeger fit together in production.16m✓
  2. 02SLI, SLO, SLA, and Error Budgets: Making Reliability QuantitativeThe Google SRE framework for reliability: what to measure, what to target, what to promise, and how error budgets fund feature work vs reliability work.16m✓
  3. 03Resilience Patterns: Timeouts, Retries, Circuit Breakers, and BulkheadsThe defensive patterns that keep distributed systems from cascading into total failure, from Hystrix to modern service mesh implementations.17m✓
  4. 04Graceful Degradation: When Partial Service Beats No ServiceLoad shedding, feature flags, cached fallbacks, and the product-engineering decisions behind degrading one feature to save the system.16m✓
  5. 05Auto-Scaling and Capacity Planning: From HPA to Predictive ScalingHorizontal pod autoscalers, cluster autoscalers, predictive scaling, and the capacity planning math that keeps systems sized right without overspending.15m✓
  6. 06Deployment Strategies: Blue-Green, Canary, Rolling, and Feature FlagsHow to ship changes safely with blue-green, rolling, canary, and progressive delivery, plus the role of feature flags and LaunchDarkly-style tooling.17m✓
  7. 07Chaos Engineering: Breaking Things on PurposeNetflix's Chaos Monkey, the Principles of Chaos, and how to run game days and fault injection experiments without making your on-call call in sick.17m✓
  8. 08Incident Management: From Detection to Blameless PostmortemOn-call, incident command, severity levels, communication, and how to run postmortems that actually change systems instead of blaming people.16m✓
  9. 09Health Checks and Readiness: Telling the Truth About Whether You're UpLiveness, readiness, startup probes, deep vs shallow health checks, and why bad health checks cause more outages than bad code.14m✓
  10. 10Cost Optimization and FinOpsApply FinOps to reduce cloud bills without sacrificing reliability: spot instances, reserved capacity, autoscaling, storage tiering, and unit-economics thinking.14m✓
  11. 11Platform Engineering: IDPs, Golden Paths, and DXTreat the platform as a product: build internal developer platforms with Backstage, golden paths, and DORA/SPACE metrics that move developer productivity.16m✓
07Security at ScaleIdentity, tokens, service auth, secrets, compliance and supply chain.10 lessons2.7 hrs46
  1. 01Authentication vs Authorization: Identity, Permissions, and Access ModelsAuthN vs AuthZ, session vs token auth, and access control models: RBAC, ABAC, ReBAC with examples from SpiceDB, OpenFGA, and AWS IAM.14m✓
  2. 02OAuth 2.0 and OpenID Connect: Delegated Authorization and Identity Done RightThe OAuth 2.0 authorization framework, OIDC identity layer, and the Authorization Code + PKCE flow that is the modern standard for web and mobile.15m✓
  3. 03JWT Deep Dive: Signed Tokens, Claims, and the Revocation ProblemHow JSON Web Tokens work: JWS signing, JWE encryption, claim validation, key rotation, and the trade-offs of stateless auth.16m✓
  4. 04mTLS and Service-to-Service Authentication: SPIFFE, Service Mesh, and Zero TrustHow mutual TLS, SPIFFE/SPIRE, and service meshes like Istio and Linkerd authenticate services without long-lived credentials.17m✓
  5. 05Secrets Management: Vault, KMS, and the End of Secrets in Config FilesManaging API keys, passwords, and certificates with Vault, AWS Secrets Manager, KMS envelope encryption, and dynamic secrets.16m✓
  6. 06DDoS Protection and WAFs: Mitigating Volumetric and Application AttacksDefending against L3/L4 and L7 DDoS with Cloudflare, AWS Shield, and WAFs; rate limiting, bot management, and the OWASP Top 10.16m✓
  7. 07Data Residency and Compliance Architecture (GDPR, DPDP, CCPA, Right-to-Erasure)Designing multi-jurisdictional systems for GDPR, DPDP, CCPA, and LGPD with data classification, regional silos, crypto-shredding, and auditable erasure.18m✓
  8. 08Supply Chain Security: SBOM, SLSA, Sigstore, and Defending Against xz-utilsProtecting the software supply chain with SBOMs, SLSA provenance, Sigstore signing, admission policies, and lessons from xz-utils and SolarWinds.16m✓
  9. 09Privacy-Preserving Systems (Differential Privacy, Federated Learning)Design systems that protect user data by construction: differential privacy, federated learning, secure aggregation, and an introduction to homomorphic encryption.18m✓
  10. 10Post-Quantum Cryptography: Migrating to ML-KEM, ML-DSA, and a Crypto-Agile FutureWhy harvest-now-decrypt-later makes PQC urgent, what NIST standardized in 2024, and how to migrate production TLS and long-lived secrets to hybrid post-quantum cryptography.16m✓

Stage 5 Applied design

08Case Studies61 complete designs, from URL shorteners to AI search engines.61 lessons18 hrs21940
  1. 01Design a URL Shortener (TinyURL / bit.ly)An interview-grade walkthrough for a URL shortener: capacity estimation, short-code generation, hot-key caching, and an analytics pipeline that never blocks the redirect.20m✓
  2. 02Design a Pastebin (Paste Sharing Service)An interview-grade walkthrough for a Pastebin-style text sharing service: object storage split, TTL-based expiration pipelines, syntax highlighting placement, and abuse prevention.17m✓
  3. 03Design a Distributed Rate LimiterAn interview-grade walkthrough for a distributed API rate limiter: algorithm choice, Redis Lua atomicity, two-tier local+global synchronization, and fail-open failure modes.19m✓
  4. 04Design a Distributed Key-Value Store (Dynamo / Cassandra / Riak)Design a distributed KV store with consistent hashing, quorum replication, gossip membership, hinted handoff, and Merkle-tree anti-entropy repair.18m✓
  5. 05Design a Notification System (Push, SMS, Email at Scale)An interview-grade walkthrough for a multi-channel notification platform: fan-out architecture, APNs/FCM integration, retry with dead-letter queues, and device-token lifecycle.20m✓
  6. 06Design a Chat System (WhatsApp / Messenger / Signal)Staff-level design for 1:1 and small-group chat at WhatsApp scale: 500M concurrent connections, message ordering, E2E encryption, and storage model trade-offs.20m✓
  7. 07Design a Social Media Feed (Twitter / Instagram / LinkedIn)Fan-out architecture, hybrid push/pull, ML ranking pipelines, and the celebrity problem at Twitter/X scale.21m✓
  8. 08Design a Photo Sharing Service (Instagram)Design Instagram-scale photo sharing: upload pipeline, transcoding, multi-resolution image serving, CDN with origin shielding, and news feed integration.19m✓
  9. 09Design a Web Crawler (Googlebot-style)Design a distributed web crawler with URL frontier, politeness policies, content deduplication, robots.txt compliance, and Bloom-filter-backed URL dedup at billion scale.18m✓
  10. 10Design Search Autocomplete (Typeahead Suggestions)Design a low-latency autocomplete system with tries, top-K precomputation, real-time trending overlays, and multi-tier caching at Google scale.20m✓
  11. 11Design a Video Streaming Service (YouTube / Twitch / TikTok)Design a UGC video platform from upload through adaptive bitrate streaming: transcode pipeline, HLS/DASH/CMAF packaging, CDN delivery with ISP peering, and live ingest architecture.20m✓
  12. 12Design Netflix (End-to-End)A whole-system walkthrough of Netflix's architecture: microservices, Open Connect CDN, per-title encoding, Cassandra + EVCache, resilience patterns, and chaos engineering.21m✓
  13. 13Design a Ride-Hailing Service (Uber / Lyft)An interview-grade walkthrough for Uber-scale ride-hailing: H3 geospatial indexing, real-time location ingest, batched bipartite matching, surge pricing, and trip orchestration.21m✓
  14. 14Design Google Maps (Routing and Tile Rendering)Design planet-scale mapping: map tile rendering, shortest-path routing with contraction hierarchies, ETA prediction with GNNs, and offline maps.20m✓
  15. 15Design a File Sync Service (Dropbox / Google Drive)Design a Dropbox-style file sync service: block-level deduplication, delta sync, conflict resolution, versioning, and client-server reconciliation.19m✓
  16. 16Design Collaborative Editing (Google Docs / Figma / Notion)Staff-level design for real-time collaborative editing at 100K+ concurrent editors: OT vs CRDTs, presence broadcasting, offline sync, and version history.22m✓
  17. 17Design a Distributed Cache (Memcached / Redis Cluster)Design a Memcached- or Redis-style distributed cache: consistent hashing, eviction, replication, client-side sharding, and hot-key mitigation.20m✓
  18. 18Design a Recommendation System (Netflix / YouTube / TikTok)Design a two-stage recommendation system: candidate generation, ranking, collaborative filtering, content-based features, a feature store, and cold-start handling.19m✓
  19. 19Design a Ticketing System (BookMyShow / Ticketmaster)An interview-grade walkthrough for high-concurrency ticketing: seat locking with Redis SETNX, saga-based payment, virtual waiting rooms, and anti-bot defenses at 500M tickets/year scale.20m✓
  20. 20Design a Payment System (Stripe / PayPal)Design a payment system with a double-entry ledger, idempotency keys, saga-orchestrated cross-service flows, and the compliance constraints that shape every decision.19m✓
  21. 21Design a Stock Exchange (Matching Engine)Design a deterministic, low-latency matching engine: FIFO order book, price-time priority, multicast market data distribution, and co-location realities.19m✓
  22. 22Design a Food Delivery Service (DoorDash / Swiggy)Design a three-sided food delivery marketplace: dispatch with batching and reassignment, composite ETA prediction, and driver-merchant-customer coordination.19m✓
  23. 23Design a Metrics Pipeline (Prometheus / InfluxDB / Thanos)Design a time-series metrics pipeline: high-cardinality ingestion, aggregation across clusters with Thanos or Cortex, alerting, and downsampling for long-term retention.18m✓
  24. 24Design Ad-Click Aggregation (Real-Time Stream Processing)Design an ad-click aggregation system with exactly-once semantics on Kafka + Flink, real-time fraud detection, and low-latency dashboards.19m✓
  25. 25Design a Logging Platform (ELK / Loki / Splunk)Design a logging platform: ingestion at scale, index vs. label-based storage (Elastic vs Loki), retention tiering, and full-text search with BM25.19m✓
  26. 26Design a Proximity Service (Nearby Friends / Yelp)Design a proximity service for 100M users with 1M concurrent location-sharing sessions: geohash/H3/S2 trade-offs, Redis geosets, bounding-box query fan-out, privacy, and hotspot handling during events.18m✓
  27. 27Design a Real-Time LeaderboardDesign a real-time leaderboard for 10M players with 100K score updates/sec, tie-breaking, time-windowed views, friend boards, and approximate rank for the tail.19m✓
  28. 28Design a Unique ID Generator (Snowflake, ULID, TSID, UUIDv7)Design a distributed ID generator producing 10M 64-bit IDs/sec, monotonic-ish ordering, clock-skew resilience, and the four-way trade-off between Snowflake, ULID, TSID, and UUIDv7.19m✓
  29. 29Design a Hotel Reservation System (Booking.com / Airbnb)Staff-level design for hotel reservation: search/booking split, PostgreSQL exclusion constraints for date-range double-booking prevention, Temporal saga orchestration, and CDC-backed availability indexing at 85K QPS.19m✓
  30. 30Design a Distributed Job Scheduler (Airflow / Temporal / Distributed Cron)Design a scheduler for 100k registered jobs and 10k executions/sec with exactly-once execution, DAGs up to 10k nodes, late/missed run policies, and graceful scheduler upgrades.19m✓
  31. 31Design ChatGPT (Conversational AI at Scale)Design ChatGPT for 900M weekly users: multi-tenant LLM serving, session-state architecture, streaming SSE, per-user memory, safety, and multi-region deployment.20m✓
  32. 32Design an Enterprise RAG SystemDesign a multi-tenant enterprise RAG platform for 1k tenants with 10M documents each at 100 QPS/tenant: ingestion, hybrid retrieval, reranking, citation, access-control-aware retrieval, freshness, and tenant isolation.19m✓
  33. 33Design a Coding Agent (Claude Code / GitHub Copilot / Cursor)Design a coding agent serving 1M concurrent sessions across autocomplete, chat, and autonomous loop modes with repo indexing, sandboxed tool use, and streaming diff application.18m✓
  34. 34Design Perplexity (AI Search with Citations)Design an AI search engine for 50M MAU, 5k QPS peak, <2 s answer latency with inline citations: query rewriting, source retrieval, citation-grounding, streaming output, freshness, and fact-check post-processing.19m✓
  35. 35Design a Voice Agent (Alexa / Siri-Class Realtime)Design a realtime voice agent for 100M devices with 50k concurrent conversations and sub-700 ms turn latency: streaming ASR, LLM turn-taking, streaming TTS, WebRTC transport, and barge-in.18m✓
  36. 36Design a Content Moderation System at ScaleDesign moderation for 500M posts/day with <200 ms pre-publish latency, human-in-loop for 0.5% of traffic, multi-modal (text+image+video): classifier cascade, reviewer workflow, appeals, adversarial robustness.20m✓
  37. 37Design a Semantic Cache for LLM ApplicationsDesign an embedding-similarity cache for LLM prompts at 10k QPS, 70%+ hit rate, <10 ms lookup: similarity threshold calibration, invalidation on source change, per-tenant isolation, false-positive cost accounting.20m✓
  38. 38Design a Model Router and Gateway (OpenRouter / LiteLLM)Design a gateway routing 20k QPS across 50+ models and 10 providers with <30 ms routing overhead: cost/latency/quality routing strategies, provider failover, streaming pass-through, per-tenant quotas, cost attribution.18m✓
  39. 39Design a Feature Flag Service (LaunchDarkly / Harness FME / Unleash)Design a feature flag and experimentation platform for 20T evaluations/day with sub-millisecond SDK-side latency, streaming config distribution, and sub-60s kill-switch propagation.18m✓
  40. 40Design a DNS Service (Cloudflare 1.1.1.1 / Google 8.8.8.8)Design a public recursive DNS resolver serving trillions of queries/day globally with <20 ms p99 from 300+ anycast POPs: UDP/TCP/DoT/DoH/DoQ, DNSSEC validation, cache design, rate limiting, and DDoS survivability.19m✓
  41. 41Design a Dating App (Tinder / Hinge / Bumble)Design a dating app for 100M MAU handling 1.5B swipes/day with <50 ms card loads: two-tower recommendations, geospatial filtering, mutual-match detection, and safety-at-scale.17m✓
  42. 42Design an Online Auction (eBay / Catawiki)Design an online auction for 100M active listings and 10M concurrent bidders: Redis Lua CAS for atomic bids at 1M/sec peak, proxy bidding, sniping extensions, and WebSocket fan-out.18m✓
  43. 43Design a Multi-Tenant SaaS PlatformDesign a multi-tenant SaaS platform serving 50K tenants with per-tenant SLA tiers, metered billing, noisy-neighbor containment, and zero cross-tenant data leakage.18m✓
  44. 44Design a Video Conferencing System (Zoom / Google Meet)Design a video conferencing platform for 500K simultaneous meetings and 10M concurrent participants with <150 ms audio and <500 ms video: SFU vs MCU vs P2P, simulcast and SVC, bandwidth estimation, regional media routing, and real-time recording.17m✓
  45. 45Design an Email Service at Gmail Scale (1.8B Users, 300B Messages/Day)Design a global email service for 1.8B users and 300B messages/day: SMTP ingress, spam pipeline cascade, per-user sharded search, RFC 5322 threading, and exabyte-scale tiered storage with content-addressed attachment dedup.20m✓
  46. 46Design Live Comments at Scale (FB Live / YouTube Live / Twitch Chat)Design a live-comment system for 10M concurrent viewers and 100K commenters on one stream: delta-batched fan-out, pre-publish moderation, and the celebrity-stream hotspot.19m✓
  47. 47Design a Fraud Detection System (Stripe Radar / PayPal / Feedzai)Design a real-time fraud detection service scoring millions of events per second under 100 ms p99 with a rules-ML cascade, online/offline feature store, graph ring detection, and analyst feedback loop.18m✓
  48. 48Design a Fitness Tracking Service (Strava / MapMyRun)Design a fitness tracking service for 195M+ users: GPS ingestion, two-stage segment matching with H3 pre-filter and DTW, Kafka-backed leaderboards, and privacy-safe planetary heatmaps.17m✓
  49. 49Design an Online Judge (LeetCode / Codeforces / HackerEarth)Design an online judge for 1M users at 100K submissions/hour peak with <15s verdict p99: Firecracker sandboxes, priority queueing for contests, seccomp + cgroups isolation, and MOSS-style plagiarism detection.18m✓
  50. 50Design a Price Tracking Service (CamelCamelCamel / Honey / Keepa)Design a price-tracking service that watches 100M product URLs with priority-driven scraping, diff-based alerting to 10M subscribers, 2-year historical retention, and polite rotation through a proxy pool that retailers actively try to block.19m✓
  51. 51Design an API Gateway at Scale (Kong / AWS API Gateway / Apigee / Envoy)Design an API gateway that handles 100K RPS per instance with <5 ms p99 overhead across 10K upstream services: routing trie, local+global rate limiting, mTLS termination, hitless config reload, and circuit breaking.17m✓
  52. 52Design a CI/CD Platform (GitHub Actions / GitLab CI / CircleCI)Design a CI/CD platform for 100K orgs and 10M workflow runs/day: YAML DAG execution, ephemeral runner pools (Firecracker), content-addressed artifacts, dependency caches, secrets injection, and multi-tenant isolation at 40K concurrent runners.18m✓
  53. 53Design an Observability Platform (Datadog / New Relic / Honeycomb)Design a unified observability platform for 10M hosts and 1B events/sec: OTLP ingestion across metrics, logs, and traces, cardinality control, trace-log correlation, multi-tenant isolation, and query latency at 100K concurrent analysts.17m✓
  54. 54Design a Search Engine (Google-Scale / Brave Search)Design a web-scale search engine over 10B documents serving 100K queries/sec at <200 ms p99: sharded inverted index, BM25 + PageRank + neural re-ranking cascade, query understanding, and freshness pipelines.19m✓
  55. 55Design a Brokerage Platform (Robinhood / E*TRADE / Interactive Brokers)Design a retail brokerage for 30M users: order routing, symbol-channel quote fanout, fractional-share aggregation, tax-lot accounting, and seven-year regulatory audit.18m✓
  56. 56Design Channel-Scale Chat (Discord / Slack)Design channel-scale chat for 100K+ member channels with pub/sub fanout, RBAC on the hot path, presence aggregation, and workspace search.18m✓
  57. 57Design a Sales Ranking by CategoryCompute each category's best sellers from a week of orders with batch jobs, and serve them with a read-optimized store and cache.6m✓
  58. 58Design a Personal Finance AggregatorA budgeting app in the style of Mint: link bank accounts, import and categorize transactions, track budgets and handle sensitive data.6m✓
  59. 59Design a Social Graph SearchFind the shortest connection between two people when the friend graph spans many machines: sharding, bidirectional search and caching.7m✓
  60. 60Design a Search Query CacheCache recent search results in memory: normalizing queries, building an LRU cache with a hash map and linked list, and scaling it out.7m✓
  61. 61Design a System That Scales to Millions of UsersGrow a web app one bottleneck at a time, from a single server to tens of millions of users, with examples using common cloud services.7m✓
09AI & ML System DesignServing models, retrieval, vector search, agents and ML infrastructure.15 lessons4.2 hrs69
  1. 01LLM Serving Architecture (vLLM, TGI, TensorRT-LLM)Design a production LLM inference stack: continuous batching, paged attention, KV-cache management, and multi-tenant GPU scheduling.15m✓
  2. 02RAG Pipelines (Retrieval-Augmented Generation)Design production RAG: chunking, embedding models, hybrid dense-plus-sparse retrieval, reranking, and the eval loops that keep it honest.17m✓
  3. 03Vector Search at Scale (HNSW, IVF-PQ, DiskANN)Design billion-scale vector search: HNSW, IVF-PQ, and DiskANN indexes, product quantization, hybrid BM25-vector search, and sharding strategies.15m✓
  4. 04AI Agent Architectures (ReAct, Reflection, Planning, Tool Use, Memory)The canonical patterns for turning an LLM into an agent: ReAct's think-act-observe loop, reflection and self-critique, planner-executor decomposition, tool use and function calling, and how agents manage short- and long-term memory.17m✓
  5. 05Multi-Agent Orchestration (LangGraph, OpenAI Agents SDK, AutoGen, Swarm)Composing multiple agents into a reliable system: orchestrator-worker topologies, handoffs and delegation, shared memory, parallel fan-out, and the failure modes of agent graphs.17m✓
  6. 06LLM Evaluation and Observability (Ragas, LangSmith, TruLens, LLM-as-Judge)How to evaluate LLM systems before and after they ship: golden datasets, reference-free metrics, LLM-as-judge, continuous eval pipelines, and the observability stack for production LLMs.17m✓
  7. 07LLMOps and Prompt Engineering (Versioning, Guardrails, Red-Teaming)The operational side of shipping LLM features: prompt-as-code, versioning, rollback, A/B testing prompts, structured outputs, and red-teaming before launch.18m✓
  8. 08LLM Cost Optimisation (Semantic Cache, Model Routing, Cascading, Prompt Caching)The cost-engineering toolbox for production LLMs: semantic caching, model routing, cascade small-then-big, prompt caching (Anthropic, OpenAI), and the unit economics that decide per-request margin.18m✓
  9. 09LLM Safety and Guardrails (OWASP LLM Top 10, Prompt Injection, PII, Jailbreaks)The safety-engineering surface for LLM applications: OWASP LLM Top 10, prompt-injection defence, PII redaction, jailbreak containment, and the defence-in-depth model for public-facing agents.16m✓
  10. 10ML System Design FundamentalsThe classic ML systems backbone every modern AI product sits on: candidate generation, ranking, two-tower embeddings, offline/online feature parity, and the training-serving skew problem.16m✓
  11. 11Feature Stores and Model Serving (Feast, Tecton, KServe, BentoML, MLflow)The infrastructure that makes ML shippable: online and offline feature stores, the model registry, model servers, shadow deploys, and the production lifecycle around a trained model.18m✓
  12. 12Recommendation Systems Deep Dive (DLRM, Two-Tower, Embedding Retrieval, Cold Start)How modern recommenders actually work end-to-end: candidate gen via ANN on embeddings, DLRM-style ranking, exploration-exploitation, cold-start handling, and the evaluation loop that keeps metrics honest.16m✓
  13. 13Realtime AI and Voice Agents (Streaming Inference, WebRTC, LiveKit, Deepgram)Designing sub-second voice agents: streaming ASR, low-latency LLM inference, streaming TTS, WebRTC transport, interruption handling, and the end-to-end latency budget.16m✓
  14. 14Multimodal AI Systems (CLIP, Whisper, LayoutLM, Document AI)Designing systems that ingest images, audio, video, and documents: CLIP-style embeddings for cross-modal retrieval, Whisper pipelines, OCR-plus-layout models, and the storage architecture for unstructured data.17m✓
  15. 15Data Infrastructure for AI (Embedding Pipelines, Chunking, Unstructured ETL, MCP)The data plane that feeds AI systems: source connectors, chunking strategies, embedding at scale, metadata schema, freshness, and the Model Context Protocol as a standard interface.18m✓
10Emerging PatternsForward-looking topics such as sustainable computing.1 lessons14 min1
  1. 01Green Computing (Carbon-Aware Scheduling, PUE, Sustainable Systems)Design systems that account for carbon: carbon-aware scheduling, PUE, renewable-energy datacenters, and the Green Software Foundation practices.14m✓
11Interview FrameworkHow to run a system design interview from start to finish.6 lessons1.6 hrs51
  1. 01Interview Frameworks Compared (RESHADED, PEDALS, ADEPT)Compare the major system-design interview frameworks and pick the one you will use in every interview.16m✓
  2. 02Requirements Scoping: Functional, Non-Functional, and MoSCoWMaster the first five minutes of a system design interview: functional vs non-functional requirements, MoSCoW prioritization, and time-boxing the scope.18m✓
  3. 03Diagramming Skills for System Design InterviewsBuild whiteboard and virtual diagrams that interviewers can read: consistent notation, flow direction, and the tools (Excalidraw, Miro) that the industry prefers.14m✓
  4. 04Trade-off Articulation: Saying 'It Depends' WellLearn to verbalize design trade-offs the way senior engineers do: name the axis, state the dependency, and commit to a choice.15m✓
  5. 05Company-Specific Interview Flavors (Amazon, Google, Meta, Netflix)How the same system design question looks different at Amazon, Google, Meta, and Netflix: leadership principles, scale emphasis, product sense, and simplicity.17m✓
  6. 06Design Doc Authoring: RFCs, ADRs, and the Staff Engineer's Written OutputHow to write ADRs, design docs, and RFCs that drive alignment, record decisions, and demonstrate Staff+ engineering judgment.15m✓
✦Trade-offs LibrarySide-by-side decision guides for the most common "X vs Y" choices.23 lessons3.3 hrs122
  1. 01Strong vs Eventual ConsistencyQuick reference: when to pick linearizable consistency, when eventual is enough, and the session-guarantees hybrid that most production systems actually run.9m✓
  2. 02ACID vs BASEWhen ACID transactions earn their coordination cost, when BASE is the only thing that scales, and why most systems run both.9m✓
  3. 03SQL vs NoSQLWhen relational wins, when non-relational wins, and why 'SQL does not scale' is almost always wrong in 2026.9m✓
  4. 04Latency vs ThroughputWhen to optimize for the single request, when to optimize for the aggregate, and why batching has a non-obvious ceiling.9m✓
  5. 05CAP and PACELC AppliedDecision guide for picking CP or AP under partition, and why PACELC's else-clause (latency vs consistency) is the choice you face on every request.8m✓
  6. 06Cache Strategies: Cache-Aside vs Write-Through vs Write-BehindDecision guide for picking the right cache-database coordination pattern: what you gain, what you lose, and why most systems use a hybrid.8m✓
  7. 07Batch vs Stream ProcessingDecision guide for choosing discrete job runs vs continuous flow, pinned to the freshness SLO that actually matters.8m✓
  8. 08Load Balancer vs Reverse Proxy vs API GatewayDecision guide for choosing between L4 load balancers, L7 reverse proxies, and API gateways based on your traffic layer, protocol, and policy needs.9m✓
  9. 09REST vs gRPC vs GraphQLDecision guide for picking the right API protocol based on caller identity, caching needs, and payload shape.9m✓
  10. 10Polling vs Long-Polling vs SSE vs WebSockets vs WebhooksDecision guide for picking the right real-time pattern. Five options, each right for a different niche; the wrong one means missed updates, wasted bandwidth, or operational pain.8m✓
  11. 11Rate Limiting Algorithms: Token Bucket vs Sliding WindowDecision guide for picking the right rate-limiting algorithm. Token bucket tolerates bursts; sliding window enforces accuracy; the hybrid path layers both.8m✓
  12. 12Optimistic vs Pessimistic Concurrency ControlDecision guide for picking validate-at-commit vs lock-first concurrency. The answer depends on conflict rate, retry cost, and side effects.8m✓
  13. 13Partitioning Schemes: Range, Hash, Consistent Hash, DirectoryDecision guide for the four canonical partitioning strategies. Pick based on query pattern, rebalance cost, and hot-spot risk.10m✓
  14. 14B-tree vs LSM-tree StorageDecision guide for choosing between B-tree and LSM-tree storage engines based on read:write ratio, latency SLOs, and operational complexity.9m✓
  15. 15Monolith vs MicroservicesDecision guide for the architecture choice that mirrors your org chart. Team size and domain stability decide, not traffic.8m✓
  16. 16Replication Topologies: Leader-Follower, Multi-Leader, LeaderlessDecision guide for picking how writes propagate: single-leader, multi-leader, leaderless, or per-range-leader hybrid.9m✓
  17. 17Distributed Transactions: 2PC vs Saga vs TCCDecision guide for choosing between two-phase commit, saga compensations, and try-confirm-cancel based on isolation needs, transaction duration, and participant control.8m✓
  18. 18Push vs Pull (Fan-out, Messaging, Feed)Decision guide for the fundamental data-propagation choice: push front-loads compute on writes, pull back-loads it on reads. The fan-out ratio decides.9m✓
  19. 19Lambda vs Kappa ArchitectureDecision guide for choosing two pipelines (batch + stream) vs one (stream-only with log replay) for analytics data systems.9m✓
  20. 20Vertical vs Horizontal ScalingDecision guide for scaling up a single machine vs scaling out across many. Default: vertical first, horizontal only when measured bottlenecks demand it.8m✓
  21. 21Normalization vs DenormalizationDecision guide for choosing between strict 3NF schemas and redundant pre-joined data, with the hybrid CDC-projection pattern most production systems actually run.9m✓
  22. 22Single-Region vs Multi-Region DeploymentDecision guide for deployment geography: single-region is the default, multi-region is the most expensive choice you can make, and regional pinning is the hybrid most teams actually need.9m✓
  23. 23Push vs Pull CDNsDecision guide for how content reaches a CDN: upload it ahead of time, or let the edge fetch it on the first request.5m✓

BeginnerIntermediateAdvanced

How to get the most out of it

Read, explain, revisit

01

Read in order first

Lessons list their prerequisites at the top. The stages are ordered so you rarely meet a term before it's explained.

02

Write it in your own words

Summarizing the idea and its trade-offs is the quickest way to find what you haven't understood yet.

03

Come back to the diagrams

When revising, skim the diagrams and tables before re-reading. If you can explain each one, you know the lesson.

The lessons in this course are adapted from the System Design handbook in The Engineering Handbook by Handbook Academy and contributors, licensed under CC BY-SA 4.0. Some lessons are adapted from The System Design Primer by Donne Martin (CC BY 4.0), as noted on each. The course structure, stage groupings and summaries on this page were written for Engineering Path. Credits & license.