Design a YouTube View Counter With Fraud Filtering
Last updated: November 29, 2026
Quick Overview
Design the system that counts video views on YouTube, showing a near-real-time count on the watch page while filtering out bot and repeat views before counts are used for monetization.
0
0
0 solved
Design the system that counts video views on YouTube, showing a near-real-time count on the watch page while filtering out bot and repeat views before counts are used for monetization.
A classic Google-flavored design question because it mixes a hot write path, eventual consistency, and integrity requirements tied to creator payouts. Interviewers check whether you separate the fast approximate display count from the slower, audited count.
What the Interviewer Expects
- Separates display count from billing-grade count
- Handles hot keys for viral videos
- Describes dedup and fraud filtering stages
- Discusses idempotent event ingestion
- Explains reconciliation and correction of counts
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 video getting 1M views per minute at premiere?
- How would you correct a count after fraud is detected days later?
- How do you show a creator a per-country breakdown?
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
Functional: record a view when playback passes a threshold (say 30 s or full play for short videos); show a count on the watch page within about a minute; provide audited counts for monetization a...
High-Level Design
- Player sends a signed view event (video id, session id, client signals, timestamp, event id) to a regional ingest frontend.
- Ingest validates the signature, drops obvious garbage, and wri...