PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCoaches
|Home/System Design/Netflix

Design an ad frequency capping system

Last updated: Mar 29, 2026

Quick Overview

This question evaluates expertise in designing low-latency, high-throughput distributed systems for stateful online decisioning, encompassing competencies in real-time counters, event ingestion, rolling time-window semantics, consistency trade-offs, and cross-device identity mapping.

  • medium
  • Netflix
  • System Design
  • Software Engineer

Design an ad frequency capping system

Company: Netflix

Role: Software Engineer

Category: System Design

Difficulty: medium

Interview Round: Onsite

Design a **frequency capping** system for an ads platform. An ad server must decide, for each ad impression opportunity, whether showing an ad would violate frequency caps such as: - Per-user per-campaign cap (e.g., max 3 impressions per user per 24 hours) - Per-user per-ad cap (creative-level) - Optional: per-user per-advertiser cap - Optional: cross-device identity (multiple device IDs map to one user) ### Requirements 1. **Online decisioning**: At serve time, given `(user_id, candidate_campaign_ids, now)`, filter out campaigns that would exceed caps. 2. **Event ingestion**: After an ad is shown, an impression event must update the counters used for future decisions. 3. **Time windows**: Support rolling windows (e.g., last 1 hour, 24 hours, 7 days). 4. **Scale** (assume): 100K–1M QPS serving; similar order impression events. 5. **Latency**: p99 decisioning latency budget ~10–20 ms at the ad server. 6. **Correctness**: Prefer not to exceed cap; small under-delivery is acceptable. Handle duplicates and late events. ### Deliverables - APIs and data flow - Storage/data model for counters - How you enforce rolling time windows - Consistency strategy (exact vs approximate) - Failure modes, edge cases, and monitoring

Quick Answer: This question evaluates expertise in designing low-latency, high-throughput distributed systems for stateful online decisioning, encompassing competencies in real-time counters, event ingestion, rolling time-window semantics, consistency trade-offs, and cross-device identity mapping.

Related Interview Questions

  • Design Ad Frequency and Order Tracking - Netflix
  • Design Rolling-Window Ad Frequency Capping - Netflix (medium)
  • Design ad frequency capping - Netflix (medium)
  • Design a File Backup System - Netflix (hard)
  • Design an Ad Frequency Capping System - Netflix
Netflix logo
Netflix
Feb 4, 2026, 12:00 AM
Software Engineer
Onsite
System Design
28
0
Loading...

Design a frequency capping system for an ads platform.

An ad server must decide, for each ad impression opportunity, whether showing an ad would violate frequency caps such as:

  • Per-user per-campaign cap (e.g., max 3 impressions per user per 24 hours)
  • Per-user per-ad cap (creative-level)
  • Optional: per-user per-advertiser cap
  • Optional: cross-device identity (multiple device IDs map to one user)

Requirements

  1. Online decisioning : At serve time, given (user_id, candidate_campaign_ids, now) , filter out campaigns that would exceed caps.
  2. Event ingestion : After an ad is shown, an impression event must update the counters used for future decisions.
  3. Time windows : Support rolling windows (e.g., last 1 hour, 24 hours, 7 days).
  4. Scale (assume): 100K–1M QPS serving; similar order impression events.
  5. Latency : p99 decisioning latency budget ~10–20 ms at the ad server.
  6. Correctness : Prefer not to exceed cap; small under-delivery is acceptable. Handle duplicates and late events.

Deliverables

  • APIs and data flow
  • Storage/data model for counters
  • How you enforce rolling time windows
  • Consistency strategy (exact vs approximate)
  • Failure modes, edge cases, and monitoring

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More Netflix•More Software Engineer•Netflix Software Engineer•Netflix System Design•Software Engineer System Design
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.