Back to All Concepts
System DesignStreamingContent DeliveryAdvanced

System Design: Netflix (Video Streaming)

Delivering high-quality video to millions of users globally using CDNs, Adaptive Bitrate Streaming, and Microservices.

The Content Delivery Network: Open Connect

You don't stream video from a Netflix server in California. You stream it from a box down the street. This is the power of Open Connect, Netflix's proprietary CDN.

How Open Connect Works

  1. Appliances: Netflix manufactures custom storage servers (Open Connect Appliances or OCAs). These are red boxes packed with SSDs and HDDs.
  2. ISP Partnership: They give these boxes to ISPs (Comcast, Verizon, AT&T) for free. The ISPs install them directly in their local exchanges.
  3. Proactive Caching: Netflix predicts what you will watch tomorrow. During off-peak hours (4 AM), they "push" the new episode of Stranger Things to the OCA in your neighborhood.
    • Result: When you press play, the data travels only a few miles. 95% of traffic never touches the public internet backbone.

Adaptive Bitrate Streaming (ABS)

Netflix doesn't just send one video file. They encode the original master into dozens of variants:

  • Codecs: H.264 (older compatibility), H.265/HEVC (4K efficiency), AV1 (royalty-free).
  • Resolutions: 480p, 720p, 1080p, 4K.
  • Bitrates: Low, Medium, High.

This creates a matrix of files. Each file is chopped into 4-second chunks.

The Manifest

When you press play, your device downloads a Manifest file (MPD or m3u8). It lists all available chunks.

Chunk 1: [1080p-High, 720p-Med, 480p-Low]
Chunk 2: [1080p-High, 720p-Med, 480p-Low]
Click to expand code...

Client-Side Logic:

  1. Device measures bandwidth (e.g., 50 Mbps).
  2. Device requests Chunk 1 in 1080p-High.
  3. Network dips to 2 Mbps.
  4. Device requests Chunk 2 in 480p-Low to avoid buffering.
  5. Network recovers.
  6. Device requests Chunk 3 in 1080p-High.

High-Level Architecture

mermaid
graph TD
    User[User Device]
    
    subgraph "Control Plane (AWS)"
        API[API Gateway]
        Auth[Auth Service]
        Recs[Recommendations]
        Billing[Billing]
    end
    
    subgraph "Data Plane (Open Connect)"
        OCA1[ISP Appliance (New York)]
        OCA2[ISP Appliance (London)]
        S3[AWS S3 Master Copy]
    end
    
    User -->|Login/Browse| API
    API --> Auth
    API --> Recs
    
    Recs -->|'Play Movie X'| API
    API -->|Manifest URL| User
    
    User -->|Request Video Chunks| OCA1
    
    S3 -.->|Pre-fill (Nightly)| OCA1
    S3 -.->|Pre-fill (Nightly)| OCA2
Click to expand code...

Backend Services (Microservices)

Netflix was a pioneer in Microservices. A single request to "load homepage" might fan out to 50+ services:

  1. Steering Service: Decides which OCA is closest to the user.
  2. Playback Service: Verifies DRM license and concurrency limits (screens active).
  3. Zuul / EVC: The Gateway that handles routing and resilience.

Data Stores

  • Cassandra: Used for high-volume write data like "viewing history" (bookmarks). It handles the massive throughput of millions of users scrubbing videos simultaneously.
  • EVCache: A wrapper around Memcached to reduce database load.

About ScaleWiki

ScaleWiki is an interactive educational platform dedicated to demystifying distributed systems, software architecture, and system design. Our mission is to provide high-quality, technically accurate resources for software engineers preparing for interviews or solving complex scaling challenges in production.

Read more about our Editorial Guidelines & Authorship.

Educational Disclaimer: The architectural patterns and system designs discussed in this article are based on common industry practices, technical whitepapers, and public engineering blogs. Actual implementations in enterprise environments may vary significantly based on specific product requirements, legacy constraints, and evolving technologies.

Related Articles