System Design Interview Questions
Core system design interview questions for mid and senior engineers, covering how to approach the problem plus scaling, caching, databases, and availability — each with a concise answer. Then practice a live mock.
10 common System Design questions
How do you approach a system design question?
Clarify functional and non-functional requirements and scale, do rough capacity estimates, define the APIs and data model, sketch a high-level architecture, then deep-dive components and discuss trade-offs and bottlenecks.
Horizontal versus vertical scaling?
Vertical scaling means a bigger machine — simple but has a ceiling and a single point of failure. Horizontal scaling adds more machines — it scales much further but needs load balancing and stateless services.
What does a load balancer do?
It distributes incoming traffic across multiple servers for availability and scale, using strategies like round-robin or least-connections, and typically does health checks and can terminate TLS.
SQL versus NoSQL — when to use each?
Use SQL for structured data, complex queries, and strong transactional consistency. Use NoSQL (document, key-value, wide-column) for flexible schemas, very high write throughput, and easy horizontal scaling. Decide by access patterns.
What is caching and where do you apply it?
Caching stores frequent results closer to the user — browser, CDN, in-memory stores like Redis, or a query cache — to cut latency and load. The hard part is invalidation, so discuss TTLs and staleness.
Sharding versus replication?
Replication copies the same data to multiple nodes for read scaling and availability; sharding partitions data across nodes by a key for write and storage scaling. Large systems often use both together.
What is the CAP theorem?
During a network partition you can guarantee only two of Consistency, Availability, and Partition tolerance. In practice you trade consistency against availability, giving CP or AP systems.
How do you design for high availability?
Remove single points of failure with redundancy, load balancing, and replication across zones; add health checks, automatic failover, and graceful degradation; and measure against SLAs.
How would you implement rate limiting?
Use an algorithm like token bucket or sliding window, enforced per user or API key at the gateway, backed by a fast store such as Redis, and return HTTP 429 when the limit is exceeded.
What is a message queue and why use one?
A queue like Kafka, RabbitMQ, or SQS decouples producers from consumers, absorbs traffic spikes, and enables asynchronous processing and retries — improving resilience and scalability.
Ready to practice out loud?
Reading answers is one thing — saying them under pressure is another. Run a free AI mock interview and get scored feedback.
Start a mock interview