Video Streaming Architecture: How HLS and DASH Deliver Video to Billions
SD
ScaleDojo
May 11, 2026
3 min read600 words
Netflix's 17,000-Server CDN
Netflix delivers 15% of the world's internet traffic during peak hours. A 2-hour 4K movie is roughly 14GB. You cannot download 14GB before watching. You cannot stream it as one giant file because a 10-second WiFi hiccup would freeze everything. Netflix solved this by inventing Open Connect - 17,000 dedicated CDN servers placed inside ISPs worldwide, serving pre-positioned video segments. The technique behind this is adaptive bitrate streaming.
Player's Adaptive Algorithm:
Time Bandwidth Buffer Quality Selected Experience
------ --------- -------- ---------------- ----------
0:00 10 Mbps 0s 720p (safe start) Loading...
0:05 10 Mbps 15s 1080p (upgrade!) Crisp
0:30 10 Mbps 20s 1080p Smooth
0:45 2 Mbps 12s 480p (WiFi drop!) Slight blur
1:00 2 Mbps 8s 480p No stutter
1:15 8 Mbps 6s 720p (recovering) Getting better
1:30 12 Mbps 18s 1080p (back!) Crisp again
Key insight: quality changes are SEAMLESS.
Each segment is independently decodable.
Switching from 1080p seg047 to 480p seg048
is invisible to the viewer - no buffering wheel.
Buffer target: 30 seconds ahead
Quality rule: pick highest quality that downloads
faster than real-time playback speed
HLS vs DASH
Feature HLS (Apple) DASH (MPEG)
-------------- ------------------ ------------------
Manifest .m3u8 playlist .mpd (XML)
Segment format .ts or .fmp4 .m4s (fmp4)
Codecs H.264, H.265, AV1 Any codec
DRM support FairPlay Widevine, PlayReady
Browser support All browsers Chrome, Firefox, Edge
Latency 6-30 seconds 2-10 seconds
Live streaming Yes (LL-HLS) Yes (LL-DASH)
Standard Apple proprietary ISO standard
Netflix uses: DASH on most devices, HLS on Apple devices
YouTube uses: DASH primarily
Twitch uses: HLS for broad compatibility
Live Streaming: The Latency Challenge
Live Streaming Pipeline:
[Camera] -> [Encoder] -> [Origin Server] -> [CDN] -> [Player]
| | |
encode package decode
~1-2s ~1-3s ~1-2s
distribute
~1-5s
Total glass-to-glass latency: 4-12 seconds
Low-Latency Techniques:
- Shorter segments (0.5s instead of 6s)
- Chunked transfer encoding (send partial segments)
- WebRTC for sub-second (Twitch experiments)
Live vs VOD trade-offs:
Feature VOD Live
----------- --------------- ---------------
Segments Pre-encoded Created in RT
CDN warmup Fast (popular) Cold (new segs)
Seeking Any position Edge only
Latency Zero concern Critical metric
Interview Tip
When designing a video streaming system, say: 'I would use adaptive bitrate streaming (HLS for broad compatibility). The upload pipeline transcodes video into multiple quality levels (240p to 4K) and splits each into 2-6 second segments. A manifest file lists available qualities and segment URLs. The player's adaptive algorithm measures bandwidth and buffer level every few seconds, selecting the highest quality that downloads faster than playback speed. Segments are served from CDN edge nodes - once a popular video segment is cached at an edge, all local viewers get it without hitting origin. For live streaming, I would use LL-HLS with shorter segments to minimize latency to 3-5 seconds.'
<Architecture overview
/blockquote>
Key Takeaway
HLS and DASH slice video into small segments at multiple quality levels. The player's adaptive algorithm picks quality based on real-time bandwidth measurement. CDNs cache the static segments globally. This combination enables smooth playback for any user on any connection speed.
No comments yet. Be the first to start the thread!
Related Articles
Enjoyed this content?
Your support keeps us creating free resources
We put a lot of hours into researching and writing these guides. If it helped you, consider buying us a coffee. Every bit goes toward keeping ScaleDojo's content free and growing.
$
One-time payment via Stripe. ScaleDojo account required.