Frontend Labs
⋯
🏗️

Real-Life System Design — From First Principles to Senior-Level Interviews

From zero to senior-level system design: estimation and building blocks, distributed systems in depth, how Google, Netflix, Uber, Stripe and others really built them, 16 solved interview cases, 12 step-by-step mock interviews, and the playbook for Senior, Staff, Principal and EM loops.

71 chapters · 5 h 35 min of reading

A practitioner's guide to designing systems that scale and that the business actually needs, written as preparation for the system design loop at Google, Microsoft, Meta, Amazon, and other tier-1 companies, for every senior role: Senior, Staff, and Principal engineers; Engineering Managers, Senior EMs, and Directors; and adjacent senior tracks such as SRE, platform, data/ML, security, and solutions architecture.

Most system design material teaches you to draw boxes. Interviewers at senior levels have already seen ten thousand candidates draw the same load balancer → app servers → cache → database diagram. What they are actually scoring is whether you can:

  1. Start from a business outcome (revenue, retention, cost, risk, compliance) and turn it into measurable requirements (latency and reliability targets, durability, cost per transaction).
  2. Pick the architecture those requirements force, and say clearly what you are giving up for it.
  3. Go deep where it matters: the one or two components where the system will actually break.
  4. Think past launch day: failure modes, migration, cost growth, team ownership, how the system changes when traffic is 10× higher.

This guide builds those skills in order, starting from zero: each part assumes only the parts before it, and every forward reference is marked with the section where the idea is taught.

How the guide is organized

 Part 0   Getting Started      what system design is, plain-language glossary, how the interview
   │                           is scored, the step-by-step framework
 Part I   Beginner             estimation, building blocks, APIs, storage, caching, scaling basics
   │
 Part II  Intermediate         sharding, replication & consistency, async messaging, distributed
   │                           transactions, service boundaries, reliability, specialized indexes,
   │                           observability, security, data modeling practice
 Part III Advanced             consensus & time, multi-region & cells, data platforms, performance
   │                           at extreme scale, verification, backup & restore, AI/ML, agentic AI
 Part IV  Expert               business outcomes → architecture, cost engineering, migrations,
   │                           the leadership decision layer
 Part V   Casebook             16 interview problems solved compactly, easy → hard
   │
 Part VI  Walkthroughs         12 full mock interviews with candidate–interviewer dialogue, easy → hard
   │
 Part VII Interview Playbook   level calibration, company notes, communication, drawing designs
                               (whiteboard, paper, canvas, prototypes), the past-project round,
                               red flags, study plan, prompt bank, cheat sheets
 Appendices                    real incidents decoded · engineering-blog & paper map

Short on time? Read §1–2, §14 (reliability), §27 (business outcomes → architecture), and three cases from Part V.

How each concept is presented. Most concept sections in Parts I–IV end with three recurring blocks, and every case in Part V carries the same three:

  • 🏗️ Architecture / flow: an ASCII diagram of the components or the step-by-step request/data flow.
  • 🌍 In production: how named companies (Google, Microsoft, Amazon, Meta, Netflix, Uber, Stripe, Slack, Discord, Shopify, Figma, and others) built it, taken from their engineering blogs and papers, with the lesson each one learned.
  • ⚠️ Corner cases & deep details: the edge cases, internals, and failure modes that interviewers probe after you've drawn the happy path (expected at Staff and above; a strong differentiator at Senior).

Who this guide is for, and how to use it by role

Every senior loop uses the same building blocks. What changes by level is how far up the ladder of framing, depth, and ownership the interviewer expects you to climb. Read the parts in order; use this table to decide where to slow down:

Target role What the design round expects Where to go deepest
Senior engineer (Google L5, Meta E5, Microsoft 63–64, Amazon SDE III / L6) A complete, correct design; solid fundamentals; sensible trade-offs; able to go deep on 1–2 components when asked Parts 0–II (incl. §18 data modeling), Part V cases, Part VI walkthroughs (Steps 0–6), §64 past project
Staff engineer (L6 / E6 / 65 / Principal L7 at Amazon) Drives the session; finds the hard parts unprompted; quantifies trade-offs; failure modes, scale, evolution All of the above + Part III (§19–26), the ⚠️ corner-case blocks, Appendix A
Principal / Senior Staff and above (L7+ / E7+ / 66–67+) Reframes the problem around the business outcome; cost, migration, org, one-way doors Everything, especially Part IV (§27–30), the strategic lens in each case, Appendices A–B
Engineering Manager / Sr. EM / Director A credible architecture plus execution: staffing, sequencing, risk, operations, stakeholder alignment §1–2, §14, §16, §20, Part IV (§27–30), the EM rows of §60, §64.7
Adjacent senior tracks (SRE, platform, data/ML, security, architects, TPMs) The same framework with a different emphasis See §60.3

Wherever the guide compares levels (§1.3, §60, and the "signals by level" tables), find your target column and the one above it. Interviewers level you by the highest column you reach consistently, not occasionally.

Related guides in this wiki (this guide links to them rather than repeating them):

  • Scale, load & performance testing: percentiles, Little's Law, fan-out math, load tools
  • CDN guide (cdn/real-life-cdn-guide.md in the wiki; not yet on frontendlabs.xyz): edge caching, consistent hashing, multi-tier caches, multi-CDN
  • Security: authN/Z, TLS, threat modeling in depth
  • Kubernetes & Docker: the compute substrate most designs end up on
  • Data structures & algorithms: tries, heaps, consistent hashing, graphs used in §42, §43, §46
  • AI/ML: background for §25

Contents

71 chapters, one page each. Prefer one long page? Read the whole book on one page.

  1. Table of Contents2 min
  2. Part 0 — Getting Started
  3. 1. What System Design Is, and How the Interview Works3 min
  4. 2. The Framework: A 45–60 Minute Design, Step by Step3 min
  5. Part I — Beginner: Foundations
  6. 3. Back-of-the-Envelope Estimation5 min
  7. 4. Building Blocks & Scaling from 1 to 10 Million Users5 min
  8. 5. APIs & Communication Protocols5 min
  9. 6. Storage Fundamentals: Choosing a Database6 min
  10. 7. Caching5 min
  11. 8. Scaling Basics: Replication, Read Replicas, Statelessness4 min
  12. Part II — Intermediate: Distributed Systems Core
  13. 9. Partitioning & Sharding5 min
  14. 10. Replication & Consistency Models4 min
  15. 11. Asynchronous Processing: Queues, Logs, Streams5 min
  16. 12. Distributed Transactions: 2PC, Sagas, Outbox3 min
  17. 13. Service Boundaries: Monolith, Microservices, and Conway's Law3 min
  18. 14. Reliability Patterns & Availability Math5 min
  19. 15. Specialized Indexes: Search, Geo, Time-Series4 min
  20. 16. Observability, SLIs/SLOs & Error Budgets4 min
  21. 17. Security & Multi-Tenancy in Design4 min
  22. 18. Data Modeling Practice8 min
  23. Part III — Advanced: Distributed Systems in Depth
  24. 19. Consensus, Coordination & Time5 min
  25. 20. Multi-Region, Cells & Disaster Recovery5 min
  26. 21. Data Platforms: OLTP, OLAP, CDC & Stream Processing3 min
  27. 22. Performance at Extreme Scale: Queueing, Tails, Metastability5 min
  28. 23. Verifying Distributed Systems8 min
  29. 24. Backup & Restore as a Discipline8 min
  30. 25. AI/ML & LLM Systems Design4 min
  31. 26. Agentic AI Systems6 min
  32. Part IV — Expert: Strategy, Economics & Leadership
  33. 27. Business Outcomes → Architecture: The Translation Layer6 min
  34. 28. Cost Engineering & Unit Economics4 min
  35. 29. Evolution & Migrations Without Downtime4 min
  36. 30. The Leadership Layer: Decisions, Org, Risk4 min
  37. Part V — Casebook: Real Interview Problems, Solved
  38. 31. URL Shortener (warm-up)3 min
  39. 32. Distributed Rate Limiter4 min
  40. 33. News Feed / Timeline5 min
  41. 34. Chat & Messaging (WhatsApp / Teams)4 min
  42. 35. Notification Platform3 min
  43. 36. Ride-Hailing & Proximity Search (Uber)4 min
  44. 37. Video Streaming (YouTube / Netflix)4 min
  45. 38. Distributed Key-Value Store (Dynamo)3 min
  46. 39. Payments & Ledger (Stripe)4 min
  47. 40. Ticketing & Flash Sales (Ticketmaster)3 min
  48. 41. Collaborative Editing (Google Docs / Office 365)3 min
  49. 42. Search Autocomplete / Typeahead3 min
  50. 43. Web Crawler3 min
  51. 44. Ad Click Aggregation & Top-K3 min
  52. 45. File Sync & Storage (Dropbox / OneDrive / Drive)3 min
  53. 46. Distributed Job Scheduler3 min
  54. Part VI — Step-by-Step Interview Walkthroughs
  55. 47. How to Use These Walkthroughs1 min
  56. 48. Walkthrough: Design Instagram13 min
  57. 49. Walkthrough: Design a CDN11 min
  58. 50. Walkthrough: Design Web Search (Google)4 min
  59. 51. Walkthrough: Design Google Maps Routing & Navigation4 min
  60. 52. Walkthrough: Design Object Storage (S3)4 min
  61. 53. Walkthrough: Design a Metrics Monitoring & Alerting Platform4 min
  62. 54. Walkthrough: Design a Global Configuration & Feature-Flag Platform4 min
  63. 55. Walkthrough: Design a Secrets Manager & Key Management Service (KMS)4 min
  64. 56. Walkthrough: Design a Certificate Authority / Cert-Minting Service14 min
  65. 57. Walkthrough: Design a Service Mesh11 min
  66. 58. Walkthrough: Design a Cluster Scheduler / Container Orchestrator (Kubernetes, Borg)4 min
  67. 59. Walkthrough: Design a Stock Exchange Matching Engine5 min
  68. Part VII — Interview Playbook
  69. 60. Level Calibration: Senior, Staff, Principal, and Engineering Managers6 min
  70. 61. Company-Specific Notes: Google, Microsoft, Meta, Amazon & Others2 min
  71. 62. Communication: Driving the Whiteboard1 min
  72. 63. Drawing System Designs: Whiteboard, Paper, and Virtual Canvas10 min
  73. 64. "Walk Me Through a System You Designed" — The Past-Project Deep Dive10 min
  74. 65. Red Flags & Common Failure Modes1 min
  75. 66. An 8-Week Study Plan2 min
  76. 67. Interview Prompt Bank: Real-World Questions, Mapped6 min
  77. 68. Cheat Sheets & Further Reading3 min
  78. Appendices
  79. Appendix A — Real Incidents, Decoded4 min
  80. Appendix B — Engineering Blog & Paper Map5 min

Generated from real-life-system-design-guide.md · 8 Oct 2026 16:36