Design the YouTube Subscriptions Feed With Hybrid Fan-Out
Last updated: November 29, 2026
Quick Overview
Design the YouTube Subscriptions tab that lists new uploads, Shorts, and live streams from channels a user follows in reverse chronological order, for users following thousands of channels and channels with 100M+ subscribers.
0
0
0 solved
Design the YouTube Subscriptions tab that lists new uploads, Shorts, and live streams from channels a user follows in reverse chronological order, for users following thousands of channels and channels with 100M+ subscribers.
A Google onsite staple dressed in YouTube specifics. The interviewer looks for the push versus pull trade-off, special handling for mega channels, and a correct merge with pagination.
What the Interviewer Expects
- Compare fan-out on write versus fan-out on read with numbers
- Use a hybrid that pulls for channels with huge subscriber counts
- Paginate with a stable cursor across merged sources
- Handle unsubscribes, deleted videos, and private uploads
- Keep the feed fresh within seconds to minutes
Key Topics to Cover
How to Approach This
- Start by clarifying functional and non-functional requirements with the interviewer.
- Estimate the scale: QPS, storage, bandwidth. This drives your design decisions.
- Draw a high-level architecture first, then deep dive into 1-2 critical components.
- Discuss trade-offs explicitly (e.g., consistency vs availability, SQL vs NoSQL).
- Address failure scenarios, monitoring, and how the system handles 10x traffic spikes.
Possible Follow-up Questions
- How do you handle a creator who uploads 50 Shorts in an hour?
- How would you add a 'Live now' section at the top?
- What if the product wants light ranking instead of pure chronology?
Sharpen Your Skills on Codemia
Practice similar problems with our interactive workspace, get AI feedback, and track your progress.
Practice System Design ProblemsSample Answer
Requirements
- Show uploads from subscribed channels, newest first, with filters (Videos, Shorts, Live).
- 2B logged-in users; average 100 subscriptions, power users up to 5,000; top channels exceed 200M subscribe...
High-Level Design
- Subscription Graph (Spanner):
user -> channelsand a reverse indexchannel -> subscriber shards. - Upload Events published by the upload pipeline once a video becomes public.
- **Fan-out...