System design interview solutions

Worked answers to 8 classic system design interview questions. Each solution covers requirements, capacity estimates, API and data model, a high-level architecture diagram, and the trade-offs interviewers push on.

Solution library

8 full walkthroughs with diagrams

Haven't tried it yet?

Practice each question stage by stage, or run a timed mock, before reading the answer.

Practice questions
001

Design a URL ShortenerVideo

Design a service like TinyURL or Bitly that turns long URLs into short, unique aliases and redirects users back to the original.

hashingdatabases
easy
002

Design a Rate LimiterVideo

Design a rate limiter that caps how many requests a client can make in a time window, with token bucket and sliding window strategies.

algorithmscaching
medium
003

Design PastebinVideo

Design a service that lets users store and share text snippets with shareable links, expiration, and read-heavy access patterns.

storagedatabases
easy
004

Design TwitterVideo

Design a social feed that supports posting tweets, following users, and building a low-latency home timeline at scale.

fan-outcaching
hard
005

Design a Chat App (WhatsApp)Video

Design a real-time chat app like WhatsApp: WebSocket gateways, presence, per-chat message ordering, delivery receipts, and delivering to phones that are offline.

websocketsmessaging
hard
006

Design a Web CrawlerVideo

Design a web crawler that fetches a billion pages a month: a URL frontier with per-host politeness, robots.txt, URL and content dedup, distributed fetchers, spider traps, and recrawl scheduling.

crawlingqueues
hard
007

Design a Key-Value StoreVideo

Design a distributed key-value store like Dynamo or Cassandra: consistent hashing with virtual nodes, replication to N nodes, tunable quorums, surviving node failures with hinted handoff and anti-entropy, conflict resolution, and an LSM-tree storage engine.

partitioningreplication
hard
008

Design a Notification SystemVideo

Design a notification system that sends push, SMS and email: user preferences and quiet hours, fan-out of a broadcast to 10 million users, per-channel queues, retries with backoff, a dead-letter queue, and an idempotency key so nobody gets the same notification twice.

queuesfan-out
hard