System design concepts · Think Like a Designer

Back-of-the-Envelope Estimation for System Design Interviews

You don't need a calculator. You need a handful of anchor numbers, a habit of rounding aggressively, and the courage to say "roughly".

What you'll be able to explain
  • Recall the latency and throughput numbers that matter
  • Convert daily users into QPS in your head
  • Estimate storage, bandwidth, cache memory and server counts
  • Use estimates to make design decisions, not just to show math
  • Work through four fully solved estimation drills

Why estimate at all

Estimation answers one question: which architecture is even possible? 100 writes per second fits on a laptop. 1 million writes per second needs partitioning and a log. 10 PB of video can't live on database disks. The numbers decide the shape before any technology is named.

Tip

Always end an estimate with a decision: "...so a single primary is fine", "...so we must shard", "...so the CDN carries 95% of bytes". A number with no consequence is wasted time.

Anchor numbers

Time

L1 cache reference~1 nsMain memory read~100 nsRead 1 MB from RAM~10 µsRedis GET in same DC~0.3 msSSD random read~0.1 msRead 1 MB from SSD~0.5–1 msRound trip in one DC~0.5 msSimple indexed DB query~1–5 msHDD seek~10 msMumbai ↔ Singapore RTT~60 msMumbai ↔ US-East RTT~200 ms
Approximate latency of common operations (log-ish scale for intuition; the bars are not to exact scale).

The lesson: memory is ~1000× faster than disk-ish operations, and the network across continents dwarfs everything. Avoid unnecessary round trips, especially cross-region ones.

Sizes and powers of two

Power Exact-ish Name Handy example
2¹⁰ 1 thousand KB A short JSON response
2²⁰ 1 million MB A compressed photo
2³⁰ 1 billion GB 1 hour of HD video ≈ 1–3 GB
2⁴⁰ 1 trillion TB A large SSD
2⁵⁰ 1 quadrillion PB A large photo platform's yearly uploads

Throughput rules of thumb

Numbers to remember
  • One stateless app server (8 cores): 1,000–10,000 simple requests/s, depending on work per request.
  • One well-indexed relational DB primary: 5,000–20,000 simple writes/s, tens of thousands of reads/s with caching of pages.
  • One Redis node: ~100,000+ operations/s.
  • One Kafka partition: ~10 MB/s comfortably; a broker handles hundreds of MB/s.
  • One server can hold ~50,000–500,000 idle WebSocket connections, memory permitting.
  • A day ≈ 86,400 s ≈ 10⁵ s. A month ≈ 2.5 million s. A year ≈ 3 × 10⁷ s.

The traffic recipe

1 · DAUDaily active users (assume or ask)2 · ActionsDAU × actions per user per day = actions/day3 · Avg QPSactions/day ÷ 10⁵4 · Peak QPSavg × 2–5 (spiky apps up to 10×)5 · Serverspeak QPS ÷ per-server capacity × 1.5 headroom
From users to servers in five steps.

Example. 50M DAU, each user views 20 pages and creates 2 posts per day.

  • Reads: 50M × 20 = 1B/day → 10⁹ ÷ 10⁵ = 10,000 QPS average, ~30,000 peak.
  • Writes: 50M × 2 = 100M/day → 1,000 QPS average, ~3,000 peak.
  • Ratio 10:1 → read-heavy. Cache + replicas.
  • App servers: 30,000 ÷ 2,000 per server × 1.5 ≈ 23 servers.

Storage, bandwidth and memory

Storage = items/day × bytes/item × days retained × replication factor.

Bandwidth = QPS × bytes per request. Do ingress (uploads) and egress (downloads) separately; egress is usually 10–100× larger and costs real money.

Cache memory follows the 80/20 rule: about 20% of items get 80% of traffic. Cache the daily hot set: 20% × daily read volume × item size, then round up.