Back to System design

Back-of-Envelope: Video Streaming Bandwidth

medium
Scale: PoP count × per-PoP capacity ≥ egress; transcoding compute by title volume Storage: PB-scale catalog + per-PoP cache Netflix, YouTube, Disney+
MathCapacity PlanningStreaming

Estimating bandwidth and storage for video streaming is a different muscle from tweets. The dominant metric is concurrency — how many users watch simultaneously — multiplied by average bitrate, giving aggregate egress. Netflix scale is the worked example.

ScalePoP count × per-PoP capacity ≥ egress; transcoding compute by title volume
StoragePB-scale catalog + per-PoP cache

Key Concepts

1
1. Step 1: Concurrency drives everything. Peak concurrent streams = 100M (Netflix peak hour). Avg bitrate (mixed HD/SD/4K) = 5 Mbps. Aggregate egress = 100M × 5 Mbps = 500 Tbps. This is the number to internalize: larger than total inter-DC capacity of most cloud regions, rivals the public internet between continents.
1. Step 1: Concurrency drives everything.500 Tbps
2
2. Step 2: Catalog storage. 18K titles × 1.5 hours average × ladder of 5 bitrates (235 kbps → 16 Mbps) × 2 codecs (H.264, H.265) = 30 encodings per title. HD @ 5 Mbps × 1.5 hr = ~3.4 GB; avg across ladder ~2 GB. 18K × 30 × 2 GB ≈ ~1 PB raw. Add AV1 + per-shot encoding + multi-language audio = ~2-3 PB total. Storage is not the problem; distribution is.
2. Step 2: Catalog storage.
3
3. Step 3: CDN sizing. 500 Tbps spread across 1,000+ PoPs ≈ 500 Gbps per PoP average. Dense regions (Tokyo, NY, London) do many Tbps. Each cache server: 50-100 Gbps. PoP = 10-100 servers. Cache hit rate: viewing follows heavy Zipf — top 0.1% titles = 30% of views, top 10% = 80%. PoP cache holds top 500 titles → 95%+ hit rate. Origin egress < 1%.
3. Step 3: CDN sizing.
4
4. Step 4: Transcoding + upload. New titles per week × master sizes (50-100 GB) → ingest BW (~1 Tbps, manageable). Transcoding CPU is the real cost — per-shot encoding is compute-intensive, often dominates Netflix's AWS bill.
4. Step 4: Transcoding + upload.
5
5. Sanity check. 500 Tbps cannot go through commercial peering; requires in-network CDN appliances (Netflix Open Connect inside ISPs). Compare: Disney+, Prime Video pay commercial CDN; cost scales differently. 2-3 PB catalog easily fits on 30-50 servers. Top 0.1% of titles drives the dominant load. Live streaming has tighter latency (sub-5s); short-form has massive concurrency at lower per-stream bitrate.
5. Sanity check.

Approach

Step 1 — Concurrency:
Peak concurrent streams = 100M.
Avg bitrate (mixed HD/SD) = 5 Mbps.
Egress = 100M × 5 Mbps = 500 Tbps.
Step 2 — Storage of catalog:
18K titles × 1.5h × ladder of 5 bitrates × 2 codecs = 30 encodings.
HD @ 5 Mbps × 1.5h = ~3.4 GB; avg across ladder ~2 GB.
18K × 30 × 2 GB = ~1 PB. Add AV1 + audio = ~2-3 PB.
Step 3 — CDN:
500 Tbps / 1,000 PoPs = 500 Gbps/PoP avg.
Each cache server: 50-100 Gbps. PoP = 10-100 servers.
Step 4 — Cache hit rate:
Zipf: top 500 titles → 80%+ hit rate.
Miss → regional shield → origin. <1% origin egress.
Step 5 — Upload + transcode:
New titles × master size ~1 Tbps upload.
Transcoding CPU: often the dominant compute cost.

Sanity checks

  • 500 Tbps > inter-continental peering of most ISPs. Must use in-network CDN.
  • 2-3 PB catalog fits on 30-50 servers — storage trivial vs distribution.
  • Top 0.1% of titles = ~30% of traffic. Cache effectiveness depends on Zipf.
  • Origin egress < 1% with good cache hit rate. Origin is for cold/long-tail.
  • Compare with Netflix actual: ~15% of global internet traffic at peak.

Pattern

  1. Define concurrency target (peak, not average).
  2. Pick bitrate distribution and average.
  3. Egress = concurrency × avg bitrate.
  4. Storage = titles × duration × bitrate × ladder × codecs.
  5. CDN math: PoP count × per-PoP capacity ≥ egress.
  6. Cache hit rate driven by Zipf and cache size.
  7. Identify dominant cost: usually CDN egress + transcoding compute.

Bitrate ladder

240p: 235 kbps
360p: 375-560 kbps
480p: 750 kbps - 1 Mbps
720p: 1.5-3 Mbps
1080p: 3-6 Mbps
4K: 12-16 Mbps
HDR adds ~30%
Per-shot encoding (Netflix): variable bitrate per scene → ~20% bandwidth saving

Adjustments by product

Live streaming: lower concurrency typically but tighter latency budget (<5s for live sports).

Short-form (TikTok, YT Shorts): massive concurrency, lower per-stream bitrate (≤3 Mbps).

User-generated (YouTube): catalog dwarfs Netflix; storage cost matters more.
Sports/Events: predictable spikes; pre-warm CDN.

Education / corporate: smaller scale; commercial CDN sufficient.