Scrivio Interview library
ConceptFoundations6 min read · updated 13 November 2026

A photo-sharing app has 10 million daily active users. Each user makes about 20 requests a day, and about 10 percent of users upload one photo a day, stored at an average of 2 MB.

Estimate the average and peak requests per second and the storage added per year, showing your arithmetic and assumptions.

Ten million users making 20 requests a day is 200 million requests, and dividing by about 86,400 seconds gives roughly 2,300 requests per second on average; with a peak of 2 to 3 times, we plan for about 5,000 to 7,000. One million uploads a day at 2 MB is 2 TB a day, about 730 TB a year of originals, plus 20 to 50 percent for thumbnails and resized copies. Three replicas turn that into about 2.2 PB of raw disk a year, while erasure-coded object storage needs closer to 1.3 to 1.5 times the logical size.

Why this question is asked

Back-of-the-envelope estimates are how we decide, in a few minutes, whether a design needs one database or fifty, and whether photos belong in a database or in object storage. Interviewers ask for them to see whether we can turn a story about users into numbers, keep units straight, and draw a design conclusion from the result. In this answer, we will work through the request rate, the peak, the storage per year and the effect of durability, show the arithmetic as we would on a whiteboard, and finish with what the numbers tell us about the design.

1The Two Tricks That Make Estimates Fast

The first trick is to round the number of seconds in a day. A day has 86,400 seconds; for estimates we treat it as about 100,000, or 10^5. Dividing by 10^5 is just moving a decimal point, and the result is only about 15 percent low, which we can correct for or simply mention.

The second trick is to keep units in the calculation and convert only at the end. Mixing megabytes and gigabits, or days and seconds, is where most estimate mistakes happen. It also helps to remember a few rough sizes: 1 million times 1 MB is 1 TB, and 1 TB a day is about 365 TB a year.

2Requests per Second: Average and Peak

We start with the request rate. The arithmetic is short enough to say aloud.

Text
daily requests = 10,000,000 users x 20 = 200,000,000 a day
average RPS = 200,000,000 / 86,400 s = about 2,315/s (round: 2,300)
quick version = 200,000,000 / 100,000 = 2,000/s (15 percent low)
peak RPS = 2,300 x 2 to 3 = about 5,000 to 7,000/s

Traffic is never flat. Users are concentrated in waking hours and in a few time zones, so the busiest hour typically carries 2 to 3 times the daily average. That is why we plan for 5,000 to 7,000 requests per second, not 2,300. Special events push it higher: a push notification sent to every user at once, or a launch, can produce 10 times the average for several minutes. If the product does such things, we say so and size for it or design for it, for example by staggering notifications.

3Storage Added per Year

Next comes storage. Ten percent of 10 million users upload one photo each per day, so there are 1 million uploads a day. At an average of 2 MB each, that is 2 TB of originals a day.

Text
uploads per day = 10,000,000 x 10% = 1,000,000 photos
originals per day = 1,000,000 x 2 MB = 2,000,000 MB = 2 TB
originals a year = 2 TB x 365 = 730 TB
with thumbnails = 730 TB x 1.2 to 1.5 = about 0.9 to 1.1 PB logical

The originals are not the only copies we store. A photo service typically keeps several resized versions, such as a thumbnail and one or two display sizes, and these often add 20 to 50 percent. So the logical data, the data we would count once, grows by roughly a petabyte a year.

4Durability Multiplies Storage

We never store a photo once. To survive disk and machine failures, storage systems keep redundancy, and how they do it changes the raw disk we need by a factor of two or more.

Raw disk per year for 730 TB of originals
SchemeOverheadRaw disk
Single copy1x730 TB, loses data on any disk failure
Three full replicas3xabout 2.2 PB
Erasure coding, e.g. 10 data + 4 parity1.4xabout 1 PB
Erasure coding, 1.3x to 1.5x range1.3x to 1.5xabout 0.95 to 1.1 PB

Three replicas are simple and fast to rebuild, which is why databases and many distributed file systems use them, but they triple the cost. Erasure coding splits each object into data fragments and adds parity fragments, so any few lost fragments can be rebuilt. A layout of 10 data and 4 parity fragments survives the loss of any 4 while needing only 1.4 times the space. Object stores such as Amazon S3 use erasure-coding-style schemes internally; when we buy S3 we pay for the logical size, and the provider carries the overhead. If we build our own storage, this choice decides whether we buy 1 PB or more than 2 PB of disk a year.

5What the Numbers Tell Us About the Design

The point of the estimate is the decision it supports, so we round aggressively and state the conclusion. A few thousand requests per second for metadata is well within reach of a single well-sized PostgreSQL primary with read replicas and a cache, so we do not need to shard metadata on day one. Petabytes per year of photos means object storage such as S3, not a database, with a CDN in front because photos are read far more often than written. And the read-to-write ratio, perhaps 100 to 1, tells us caching will pay off.

Being off by 20 percent in any of these numbers changes nothing. Being off by a factor of ten would, and that is the precision an estimate needs: the right order of magnitude.

Step throughFrom numbers to decisions
  1. Average RPS about 2,300Peak 5,000 to 7,000
  2. Metadata fits one primary?Thousands of RPS, gigabytes of rows
    YesPostgreSQL plus replicas and cacheNoPlan sharding
  3. Photos about 1 PB a yearFar beyond a database
  4. Store photos in object storageS3 with a CDN in front

4 steps in order. Play them, or step through them one at a time.

6Follow-up questions

What would the upload bandwidth be at peak?

One million uploads a day is about 11.6 uploads per second on average, or roughly 23 MB per second at 2 MB each, which is about 185 Mbit per second. With a peak of 3 times, that is about 70 MB per second or around 560 Mbit per second of inbound traffic, plus the same again internally if every upload is written to several replicas or processed into resized copies. That is modest for a cloud region, and uploading directly to object storage with pre-signed URLs keeps it off our application servers.

Why round 86,400 to 100,000 instead of using the exact number?

Because the inputs are themselves guesses, often off by more than 15 percent. Rounding makes the arithmetic fast enough to do aloud, and we can mention that the true figure is a bit higher.

How do you estimate the read-to-write ratio?

From user behaviour: if a typical user views 50 to 100 photos a day and uploads one every ten days, reads outnumber uploads by several hundred to one. Any ratio above about 10 to 1 already justifies caching.

7Conclusion

In this answer, we estimated about 2,300 requests per second on average and planned for 5,000 to 7,000 at peak, then found that 1 million 2 MB uploads a day add about 730 TB of originals a year, and around a petabyte with resized copies. Three replicas would need about 2.2 PB of raw disk, while erasure coding needs 1.3 to 1.5 times the logical size. The conclusion that matters is the order of magnitude: metadata fits a single primary with replicas, and photos belong in object storage behind a CDN.

What to say in the interviewAbout 80 seconds aloud

Open with

I would start with requests: ten million users times twenty requests is 200 million a day. A day is 86,400 seconds, which I round to about ten to the fifth, so that is roughly 2,300 requests per second on average.

Then, if they want more

Traffic is not flat, so I would assume a peak of two to three times and plan for about 5,000 to 7,000 per second, more if we send push notifications to everyone at once.

For storage, ten percent of users upload one photo a day, so a million photos at 2 megabytes is 2 terabytes a day, about 730 terabytes a year of originals. Thumbnails and resized copies usually add twenty to fifty percent, so call it around a petabyte of logical data a year.

Durability multiplies that: three full replicas would be about 2.2 petabytes of raw disk, while erasure coding, say ten data plus four parity fragments, needs about 1.4 times, so around a petabyte.

Then I would state what the numbers mean: a few thousand requests a second of metadata fits a single PostgreSQL primary with replicas and a cache, and petabytes a year means photos go in object storage like S3 behind a CDN, not in a database. Peak upload bandwidth is roughly 70 megabytes a second.

About this answer

Last updated
13 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the official documentation for the version you use. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "Estimate the average and peak requests per second and the storage added per year...": https://scrivio-interview-library.netlify.app/architecture/sd-fundamentals/2e11f50d65/