System Design Visualized
Lesson 2.4

Example: estimate Twitter QPS and storage

Play this lessonThis lesson comes with an interactive animation you can break, a live-code challenge and a chapter quiz.

Let's practice with made-up (not real) Twitter numbers.

📝 Assumptions

  • 300 million monthly active users
  • 50% use it daily
  • 2 tweets per user per day
  • 10% of tweets contain media
  • Data stored for 5 years

📦 Tweet size

  • tweet_id: 64 bytes
  • text: 140 bytes
  • media: 1 MB

Estimates

  • DAU = 300M × 50% = 150 million
  • Tweets QPS = 150M × 2 / 24 h / 3600 s ≈ 3,500
  • Peak QPS = 2 × QPS ≈ 7,000
  • Media storage per day = 150M × 2 × 10% × 1 MB = 30 TB
  • 5-year media storage = 30 TB × 365 × 5 ≈ 55 PB

Key takeaways

  • QPS = daily actions ÷ 86,400 seconds.
  • Peak ≈ 2× average.
  • Storage = items per day × size × retention.

Remember it, then prove it

Create a free account to save your progress, get spaced-repetition reviews of what you miss, and design real systems in the interview simulator.

Start free