System Design Interview Questions and Answers

System design interview questions with answer outlines: scalability fundamentals, caching, databases, queues, consistency, and classic designs such as a URL shortener, chat, news feed, rate limiter and video streaming.

Updated November 20, 2026 28 questions 7 min read

Key takeaways

  • System design interviews grade process and trade-offs, not one correct architecture.
  • Follow a structure: requirements → estimates → API → high-level design → deep dive → bottlenecks.
  • Know the building blocks: load balancers, caches, databases, sharding, queues, CDNs.
  • Practice classic problems: URL shortener, chat, news feed, rate limiter, notification system.
Contents

System design interviews test how you build large systems under constraints: clarifying requirements, choosing building blocks, and explaining trade-offs. There is no single correct answer. Below are 28 common questions and design prompts with answer outlines. For a step-by-step method, read our system design interview guide.

How to spend a 45-minute design round

Requirements
5 min
Functional and non-functional; what’s out of scope
Estimates
5 min
Users, requests per second, storage, bandwidth
API and data
5 min
Key endpoints and data model
High-level design
10–15 min
Main components and data flow
Deep dive
10–15 min
One or two hard parts in detail
Wrap-up
5 min
Bottlenecks, failures, trade-offs, what’s next

Numbers worth remembering

QuantityApproximate value
Seconds per day~86,400 (round to 100,000)
1 million requests per day~12 requests per second on average
Memory access vs network round trip in a data centernanoseconds vs ~0.5 ms
Disk seek vs SSD readmilliseconds vs ~0.1 ms
Cross-continent round trip~100–150 ms

See also backend and DevOps interview questions.

Fundamentals

1Vertical vs horizontal scaling?

Junior

Vertical scaling adds resources to one machine: simple, but limited and a single point of failure. Horizontal scaling adds more machines behind a load balancer: nearly unlimited, but requires stateless services and distributed data.

2What does a load balancer do?

Junior

It distributes requests across servers (round robin, least connections, consistent hashing), removes unhealthy servers via health checks, and can terminate TLS. Layer 4 balancers route connections; Layer 7 balancers route by HTTP attributes such as path or header.

3Latency vs throughput, and why percentiles matter?

Mid

Latency is the time for one request; throughput is how many requests per second the system handles. Report p50, p95 and p99 latencies: averages hide the slow requests that users notice, and tail latency grows when a request fans out to many services.

4How do you do back-of-the-envelope estimates?

Mid

Start from users and actions: daily active users × actions per user ÷ 86,400 seconds gives requests per second; multiply by a peak factor (often 2–3×). Storage: items per day × size × retention. Round aggressively and state assumptions; the goal is the order of magnitude.

5What is a CDN, and when do you use one?

Mid

A network of edge servers that cache content close to users. Use it for static assets, images and video, and increasingly for cached API responses. It reduces latency and offloads origin servers.

Data and storage

6How do you choose a database for a design?

Mid

Start from access patterns and consistency needs. Relational databases fit transactional data with relations. Key-value stores fit simple lookups at scale; wide-column stores fit heavy write workloads with known queries; document stores fit flexible schemas; search engines handle full-text queries; object storage handles files.

7Replication: leader-follower vs multi-leader vs leaderless?

Mid

Leader-follower: one node accepts writes, followers serve reads (replication lag is a concern). Multi-leader: writes in several regions, requiring conflict resolution. Leaderless (Dynamo-style): writes and reads go to several nodes with quorums, trading consistency for availability.

8What is sharding, and how do you choose a shard key?

Mid

Splitting data across databases by a key. A good shard key spreads load evenly and keeps related data together for common queries (for example, user_id for user data). Bad keys create hot spots. Consistent hashing reduces data movement when adding shards.

9Explain CAP and PACELC.

Senior

CAP: during a network partition, choose consistency or availability. PACELC adds: else (no partition), choose between latency and consistency. Real systems make this choice per feature: bank balances favor consistency; likes counters favor availability and low latency.

10Strong vs eventual consistency: how do you decide?

Senior

Ask what goes wrong if a user sees stale data. For payments, inventory and permissions, use strong consistency. For feeds, counters and analytics, eventual consistency is acceptable and scales better. Techniques like read-your-writes consistency give a good user experience in between.

Get System Design answer points in real time during your interview

Sottena listens to the interviewer, detects each question and shows short answer points in about a second. 150 free credits, no card required.

Caching and messaging

11Which caching strategies do you know?

Mid

Cache-aside (lazy loading) is the most common. Write-through writes to cache and database together. Write-back writes to cache first and persists later (fast, risk of loss). Choose TTLs and invalidation rules, and protect against stampedes and hot keys.

12What are message queues and event streams used for in designs?

Mid

To decouple producers and consumers, absorb traffic spikes, run work asynchronously and fan out events to multiple consumers. Queues (SQS, RabbitMQ) distribute tasks; logs (Kafka) keep an ordered, replayable history of events.

13How do you make operations idempotent in a distributed system?

Senior

Assign unique IDs to requests and events, store processed IDs, use upserts and conditional writes, and design state transitions so repeating them has no extra effect. This makes retries and at-least-once delivery safe.

Reliability

14How do you design for high availability?

Mid

Remove single points of failure with redundancy across availability zones, health checks and automatic failover, replicated data with backups, graceful degradation when dependencies fail, and capacity headroom. Express targets as SLOs.

15How do you handle a hot key or celebrity problem?

Senior

Cache the hot item aggressively (including local in-memory caches), replicate it across shards, split writes with sharded counters, and treat celebrity accounts differently in fan-out designs (pull instead of push).

Classic designs

16Design a URL shortener.

Mid

Requirements: create short links, redirect fast, optional analytics. Estimate reads ≫ writes. Generate IDs with a counter or ID service encoded in base62 (or random IDs with collision checks); store code → URL in a key-value store; cache popular codes; redirect with 301 or 302 depending on analytics needs; collect click events asynchronously.

17Design a rate limiter.

Mid

Decide where it runs (API gateway or middleware) and the key (user, IP, API key). Algorithms: token bucket (allows bursts), fixed or sliding window. Store counters in Redis with atomic operations; return 429 with Retry-After; decide whether to fail open or closed when the store is down.

18Design a chat application.

Senior

Persistent connections (WebSockets) to chat servers, a presence service, message storage partitioned by conversation (a wide-column store works well), message IDs ordered per conversation, delivery and read receipts, push notifications for offline users, and fan-out for group chats. Discuss ordering, retries and end-to-end encryption if required.

19Design a news feed.

Senior

Two approaches: fan-out on write (push new posts into followers’ precomputed feeds; fast reads, expensive for celebrities) and fan-out on read (build the feed at request time). Most systems use a hybrid. Add ranking, caching of feed pages, pagination with cursors and media served by a CDN.

20Design a notification system.

Senior

Producers publish notification events to a queue; a service applies user preferences, rate limits and templates, then sends through channel workers (push, email, SMS) with retries and dead-letter queues. Track delivery status, deduplicate with IDs, and respect quiet hours.

21Design a video streaming service.

Senior

Uploads to object storage, an asynchronous transcoding pipeline into several resolutions and segments (HLS/DASH), metadata in a database, delivery through a CDN with adaptive bitrate streaming, and separate services for recommendations, search and view counts.

22Design a web crawler.

Senior

A URL frontier with prioritization and politeness per domain, distributed fetchers, DNS caching, parsing and link extraction, deduplication of URLs and content (hashes), storage of pages, respect for robots.txt, and handling of traps and failures.

23Design a distributed key-value store.

Senior

Partition keys with consistent hashing, replicate each partition to N nodes, use quorum reads and writes (R + W > N for stronger consistency), handle conflicts with versioning, detect failures with gossip, and repair data with hinted handoff and anti-entropy.

24Design a typeahead (autocomplete) service.

Mid

Precompute top suggestions per prefix from query logs in a trie or prefix index, store them in memory or a fast key-value store, update periodically, cache responses at the edge, and personalize lightly at request time. Debounce requests on the client.

Interview approach

25How should you structure a system design interview?

Junior
  1. Clarify functional and non-functional requirements.
  2. Estimate scale.
  3. Define the API and data model.
  4. Draw a high-level design.
  5. Deep dive into one or two components.
  6. Discuss bottlenecks, failures and trade-offs.

Keep the interviewer involved and check priorities as you go.

26What are common mistakes in system design interviews?

Mid

Jumping into components before requirements, overengineering for imaginary scale, ignoring failures and data consistency, not stating trade-offs, and monologuing without checking what the interviewer wants to explore.

27How deep should you go into each component?

Mid

Cover the whole design at a high level first, then go deep where the interviewer shows interest or where the problem is hardest (for a chat app: message delivery and ordering; for a feed: fan-out). Breadth first, depth second.

28What do interviewers expect from senior candidates?

Senior

Driving the conversation, choosing sensible defaults quickly, identifying the real bottlenecks, discussing operational concerns (monitoring, deployment, cost, migrations) and explaining trade-offs with clear reasoning rather than listing technologies.

How to prepare

  1. Use one structure every timeRequirements, estimates, API, high-level design, deep dive, trade-offs.
  2. Practice classic problems aloudURL shortener, rate limiter, chat, feed, notifications, video.
  3. Memorize a few numbersSeconds per day, typical QPS per server, storage sizes, latency of memory vs network vs disk.
  4. Draw while you talkBoxes and arrows with data flow, then label the data stores.
  5. Always discuss failureWhat happens when each component goes down?

Get answer points in real time during your interview

Sottena listens to the interviewer, detects each question and shows short answer points in about a second. 150 free credits, no card required.

Related interview questions