Reading

System Design Primer: a free guide to designing large-scale systems on GitHub

TL;DR

System Design Primer collects large-scale design concepts (CAP, caching, sharding, queues…), solved exercises and Anki cards. Study with its four steps: use cases and constraints, high-level design, core components, then scaling and trade-offs.

Writing good code isn't enough to become senior: at some point you must answer questions like "how does this system handle 10 million users", "where should the cache go", "SQL or NoSQL". System design interviews at tech companies revolve around the same questions. System Design Primer is one of the most-starred repos on GitHub: a free, structured curriculum collecting large-scale system design concepts, solved exercises and Anki review cards.

GitHub page of donnemartin/system-design-primer
GitHub page of donnemartin/system-design-primer (screenshot, November 2026)

GitHub: https://github.com/donnemartin/system-design-primer · about 377k stars · CC BY 4.0

What's in the repo?

SectionContent
Topic indexPerformance and scalability, latency and throughput, CAP theorem, consistency and availability patterns, DNS, CDN, load balancers, reverse proxies, databases (replication, sharding, SQL and NoSQL), caching, asynchronism (queues), protocols (HTTP, TCP, UDP, RPC, REST), security
Interview questions with solutionsDesign Pastebin, the Twitter timeline, a web crawler, Mint.com, a social network, a key-value cache, Amazon's sales rank, a system on AWS scaling to millions of users; with diagrams and sample code
Object-oriented designHash map, LRU cache, call center, deck of cards, parking lot, chat server
AppendixPowers of two table, latency numbers every programmer should know, links to architecture write-ups from large companies
Anki cardsDecks for spaced-repetition review

How to study effectively

  1. Skim the whole index to see which concepts exist; the README suggests study plans by how much time you have (short, medium, long).
  2. Go deep topic by topic in order: scalability → databases → caching → asynchronism. Each section links to further reading.
  3. Practise estimation: back-of-the-envelope calculations with the latency and powers-of-two tables, e.g. storage for a year of data.
  4. Solve exercises before reading solutions, then compare.
  5. Review with Anki a few minutes a day so it sticks.

A framework for system design questions

The repo proposes four steps, useful both in interviews and when writing real design docs:

  1. Outline use cases, constraints and assumptions: who uses it, how many, read/write ratio, data size.
  2. Create a high-level design: the main components and how they connect.
  3. Design core components: APIs, data model, algorithms.
  4. Scale the design: find bottlenecks, add load balancers, caches, sharding, replication, and state the trade-offs.

Caveats

  • The repo teaches foundational concepts; some technology examples are dated. Supplement with modern architecture material (managed services, serverless, LLM-based systems).
  • Don't memorise solutions: interviewers assess how you reason and weigh trade-offs, not a single correct answer.
  • The content is licensed under Creative Commons Attribution 4.0; credit the source when reusing it for internal training.

How to apply it

  • Dev: Spend 30 minutes a day following the README's study plan, and use the four-step framework when writing design docs for real features.
  • Tech Lead: Use the exercises for internal study sessions or interview question banks, and the four-step framework as a template for design reviews.
  • PM: Read the concepts section (CAP, caching, queues, consistency versus availability trade-offs) to talk more effectively with engineers about non-functional requirements.

Sources & references

  1. donnemartin/system-design-primer — donnemartin (GitHub)