System Design
A repeatable framework for designing systems, reusable diagram building blocks, and worked case studies.
System design means turning ambiguous requirements into an architecture that you can explain and defend. This section teaches one repeatable framework of 18 steps, from functional requirements to interview follow-ups. It then applies the framework to case studies.
- Introduction to System Design presents the framework, including how to estimate capacity and how to label assumptions.
- Diagram Building Blocks is a library of reusable Mermaid snippets for load balancers, caches, brokers, replication, sharding and other components.
- Building blocks explains the reusable components: scaling steps, load balancing, caching, consistent hashing, CAP and PACELC, database choice, ID generation, queues and delivery semantics, real-time communication, deployment strategies, security fundamentals, DNS and probabilistic data structures.
- Case studies apply the framework end to end, each with an interactive architecture diagram: order management, URL shortener, rate limiter, payment system, proximity service, chat, news feed, notifications, video streaming, web crawler, search autocomplete, distributed key-value store, collaborative editing, stock exchange, ride sharing, metrics and alerting, flash sale, and file storage and sync.
For the theory behind replication, partitioning, transactions and consensus, see Data-Intensive Systems.
Topics in this section
- System Design Building BlocksThe reusable components and techniques of every large system: scaling steps, load balancers, caches, consistent hashing, CAP, database choice, ID generation, queues, real-time communication, deployment and security fundamentals.
- System Design Case StudiesWorked designs that follow the 18-step framework, with calculations and trade-offs.
Articles
- IntroductionA repeatable 18-step framework for designing systems and answering system design interviews: requirements, capacity estimation with worked calculations, APIs, data models, architecture, scaling, failure handling and trade-offs.
- Diagram Building BlocksA library of reusable Mermaid diagrams for system design — load balancer, API gateway, services, databases, caches, message brokers, object storage, search indexes, external services, replication, sharding and event flows — each with its responsibility, failure modes and trade-offs.