Stage 0 · Interview method · Easy · 15 min
Capacity and cost estimation
Turn users and actions into requests per second, storage and bandwidth. Then turn those into servers and monthly cost, and use the numbers to justify and right-size your design.
What each interview level is expected to know
Learn first: Latency, throughput and availability
In AI systems: Cost and latency
After this lesson you can:
- Turn daily users and actions into requests per second, at average and at peak.
- Estimate storage, bandwidth and cache size with round numbers.
- Turn the load into a number of servers and a rough monthly cost.
Start here
See it in 60 seconds
From daily users to requests a second
Capacity estimation turns a guess about users into requests a second, a busiest-hour peak and storage, close enough to choose the design.
Scene 1 of 6 · Start from users
Start from what you can guess: say 10,000,000 people use the app each day.
| Step | Working |
|---|---|
| Daily users (highlighted) | 10,000,000 |
- Average requests a second
- not shown yet
- Busiest-hour requests a second
- not shown yet
- Start from users. Start from what you can guess: say 10,000,000 people use the app each day.
- Requests a day. If each makes about 10 requests, that is 100,000,000 requests a day.
- Divide by a day. A day has 86,400 seconds, so that averages about 1,157 requests a second.
- Plan for the peak. Traffic is not flat, so plan for the busiest hour at about twice that: 2,314 a second.
- Then the storage. If 1 request in 10 saves 1 KB, that adds 10 GB a day, about 3.7 TB a year.
- Round, then decide. Round freely, even to 100,000 seconds a day: the answer only has to pick the design.
- Now you try. How many people use the app each day, in millions? For example: 50 million daily users: about 5,787 requests a second, 11,574 at the busiest hour, and 18.3 TB a year. That needs about 12 servers of 1,000 a second each, behind a load balancer.
Scene 1 of 6: Start from users. Start from what you can guess: say 10,000,000 people use the app each day.
Key points
- Start from daily users and requests each, then divide by 86,400 seconds for requests a second.
- Plan for the busiest hour, often about 2 times the average, not for the average.
- Storage is writes a day times the size of each, then times 365 for a year.
- Round boldly: you need the right size to choose the design, not an exact number.
In plain words
Say 10 million people use an app each day, and each makes 10 requests. That is 100 million requests a day, or a little over 1,000 a second. Capacity estimation is this kind of quick sum. It turns a guess about users into requests per second, storage and bandwidth, so you can size the design.
The sums run in a fixed order. Start from users and how often they act, then work out requests a second, data written each day, and storage over the years. Each number answers a design question: one server or many, and whether storage, memory or the network runs out first. Round freely as you go. A rough answer in a few minutes is the goal, not an exact one.
The problem it solves
Without numbers, you size by guesswork. Guess too low and the system falls over under real load. Guess too high and you pay for servers that sit idle. A rough estimate, done in minutes, avoids both.
Why it matters
A design for 1,000 users and a design for 100 million are different systems. A few quick sums tell you which one you are building: one server or hundreds, one database or many. They also show which part runs out first.
A worked example
A service handles 2,000 read requests a second, each returning a 4 KB payload. Outgoing bandwidth is 2,000 × 4 KB, which is 8,000 KB per second, or about 8 MB/s.
Think of it like…
Think of planning a road trip. You know the distance and how far the car goes on a full tank. So you can guess how many fuel stops you need.
Where this analogy stops working
A rough sum from a few known numbers is the useful part. But a trip has one fixed distance. A system's load changes by the hour and grows over the years. So you size for the busiest hour, add spare room, and correct the guess with real measurements.
Try it
See it working
Mechanics
How it works
An estimate turns what you were told into the few numbers a design needs. The pictures carry this page's own numbers through, so you can check each sum by hand.
Traffic math
Requests per second = daily users × requests per user each day ÷ seconds in a day. A day has 86,400 seconds; round it to 100,000 to make the sum quick. For example, 10 million users × 10 requests ÷ 100,000 is about 1,000 requests a second. Assume the peak is about 2 times the average.
Storage math
Storage per day = writes per day × size of one write. For example, 1 million posts a day × 1 KB each is 1 GB a day. Multiply by 365 and by the years you keep the data: 5 years is about 1.8 TB.
Bandwidth math
Bandwidth is how many bytes move each second. Incoming bandwidth = writes per second × size of one write. Outgoing bandwidth = reads per second × size of one read. For example, 1,000 reads a second × 100 KB each is 100 MB a second.
Cache sizing (80/20 rule)
Pick a case to follow belowWith this case: With no cache, all 1,000 reads a second reached the database.
- App servers — 1,000 reads a second — healthy
- Cache — in memory — healthy
- Database — on disk — healthy — NOW — 1,000 reads/s
- Database reads
Step 1 of 1Step 1 of 1 · Database
Done: All 1,000 reads reach the database
- What happens
- With no cache, every read goes to disk.
- Why
- The database must be sized for every read.
- What changes
- This number decides how big the database must be.
- Next
- The run ends here.
How it ended. With no cache, all 1,000 reads a second reached the database.
Reads a second1,000Answered by the cache0Reaching the database1,000Watch: every readCache memory0GBStep 1 of 1: Database. All 1,000 reads reach the database. With no cache, every read goes to disk.
Often about 20% of the items get about 80% of the reads. So a common first guess is to (A small, fast store that keeps copies of popular data, so most reads skip the slower database.) 20% of the data read in one day. For example, 20% of 50 GB read each day is 10 GB of memory.
In the picture, the app makes 1,000 reads a second. With no cache, all of them reach the database. With a 10 GB cache that answers about 80% of reads, only 200 a second reach the database.
So the cache estimate also changes the database estimate. The 80/20 split is a rule of thumb. Measure the real (The share of reads the cache answers by itself, without asking the database.) once the system runs.
Turn the load into servers and cost
Pick a case to follow belowWith this case: 10,000,000 daily users means a peak of about 2,000 requests a second, 4 servers and about $800 a month.
Daily users, 10 requests each Daily users 10 requests each Load balancer, sees every request, NOW Load balancer sees every request 100,000,000 a day NOW App servers, 1,000 req/s each App servers 1,000 req/s each - Daily users — 10 requests each — healthy
- Load balancer — sees every request — healthy — NOW — 100,000,000 a day
- App servers — 1,000 req/s each — healthy
- Requests
Step 1 of 5Step 1 of 5 · Load balancer
Done: 10,000,000 users make 100,000,000 requests a day
- What happens
- Each user makes about 10 requests a day: 10,000,000 × 10.
- Why
- Start from what you were told or agreed: users, and how often each one acts.
- What changes
- Next, turn a day into seconds.
- Next
- About 1,000 requests a second on average
Requests a day100,000,000At the peak–Servers–Cost a month–Step 1 of 5: Load balancer. 10,000,000 users make 100,000,000 requests a day. Each user makes about 10 requests a day: 10,000,000 × 10.
What these pictures simplify. The per-server figure (1,000 requests a second), the price ($200 a month) and the 80% hit rate are examples. Real figures depend on the code, the machine and how reads spread over the items. The capacity lab lets you change every input.
Divide the peak by what one server can handle, and leave room to spare. Say one app server takes 1,000 requests a second, and you run each at 70%. The peak of 2,000 from step 1 needs 3 servers, plus 1 spare. At an example price of $200 a month each, that is $800 a month. Real servers vary a lot, so measure yours.
Switch to 30 million users. The same steps give a peak of 6,000 requests a second, 10 servers and about $2,000 a month. Three times the users needs about three times the servers, because each server adds the same capacity.
Use it when
- Early in a design, after the requirements: the numbers tell you how many servers and how much storage to draw.
- Before you choose between two designs: a quick sum often shows that the simpler one is enough.
Skip it when
- A small internal tool with low, steady traffic: one server is plainly enough, so the sums change nothing.
- Numbers the design does not depend on: skip the bandwidth sum if the system sends only small text.
Check yourself
Judgement
Trade-offs and how it fails
What you give up
- Cost
- A cache sized too large wastes memory you pay for. A cache sized too small misses often, so more reads fall through to the database.
- Complexity
- Exact sums take time and still rest on guessed inputs. Round numbers are fast, and they are close enough to pick a design. Measure the real system later to correct them.
Failure modes
- Sizing for the average. Traffic is not flat: the busiest hour can be several times the daily average. This lesson uses 2 times as a first guess.
- Mixing units: bits with bytes, or a day with a second. Write the unit beside every number.
- Treating the estimate as exact. The inputs are guesses, so the result is a rough size, not a promise.
In the real world
- Twitter's engineering blog reported in 2013 that tweets averaged about 5,700 a second, with a record peak of 143,199 a second. That peak was 25 times the average.
- A ride-hailing example: 5 million drivers each sending a location every 4 seconds is about 1.25 million updates a second.
Trade-offs to be ready to discuss: Memory vs disk
Check yourself
Interview
What interviewers look for
- Round 86,400 seconds a day to 100,000, and say that you are rounding. It keeps the sums quick and easy to follow.
- Say what each number is for: "About 2,000 requests a second at peak, so two or three app servers."
- End the estimate with cost: "about N servers, roughly $X a month". Say which part costs the most.
Say it out loud: A service gets 500 million reads a day, and each object is 1 KB. How much memory caches 20% of one day's reads?
Expected depth by interview level
Levels describe the depth interviewers probe, not years of experience. Choose a level on the learning path to highlight it.
- JuniorUseful
- Rough requests per second and storage from daily users.
- MidCore
- Estimate load, storage and bandwidth, and use them to justify choices.
- SeniorCore
- Find the bottleneck from the numbers and size each tier.
- StaffCore
- Add cost per request and right-size; question over-built designs.
Practice
Apply it
Three harder questions
The first two use the idea on a new case. The last asks you to judge a design.
Apply it
Apply it
Judge a design
Go deeper
Sources and further reading
First-hand sources to check this page against and to go further. They are standards, official docs, original papers, and guides from engineering and security teams. Each link was opened on 8 November 2026.
- Engineering guideNon-Abstract Large System DesignGoogle SRE workbookA full design worked through with real numbers: requirements, estimates for one machine, then many.
- Research paperDesigns, Lessons and Advice from Building Large Distributed Systems (2009)Jeff Dean, LADIS keynote slidesThe source of the well-known table of rough latency numbers, with back-of-the-envelope examples.