Design Budget Pacing and Click Billing for Google Ads

Last updated: November 29, 2026

Quick Overview

Design the system that keeps each advertiser's daily spend close to their budget across a global ad-serving fleet, and bills clicks accurately with invalid-click filtering.

Google
System Design
Software Engineer
Google
November 29, 2026
Software Engineer
System Design Round
System Design
Hard

0

0

0 solved


Design the system that keeps each advertiser's daily spend close to their budget across a global ad-serving fleet, and bills clicks accurately with invalid-click filtering.

Ads is Google's core revenue system, and budget control is a classic distributed-counting problem with money at stake. Interviewers check how you share budget state across thousands of servers without a central bottleneck and how you bound overspend.

What the Interviewer Expects
  • Explains why global exact counting per auction is infeasible
  • Designs local budget allocation with periodic sync
  • Paces spend over the day rather than exhausting early
  • Builds an exactly-once billing pipeline
  • Handles invalid clicks and refunds
Key Topics to Cover
distributed counters
pacing
exactly-once processing
stream processing
financial correctness
How to Approach This
  1. Start by clarifying functional and non-functional requirements with the interviewer.
  2. Estimate the scale: QPS, storage, bandwidth. This drives your design decisions.
  3. Draw a high-level architecture first, then deep dive into 1-2 critical components.
  4. Discuss trade-offs explicitly (e.g., consistency vs availability, SQL vs NoSQL).
  5. Address failure scenarios, monitoring, and how the system handles 10x traffic spikes.
Possible Follow-up Questions
  • How much overspend do you allow, and who pays for it?
  • How does pacing react to a sudden traffic spike?
  • How do you handle a click that arrives hours after the impression?
Sharpen Your Skills on Codemia

Practice similar problems with our interactive workspace, get AI feedback, and track your progress.

Practice System Design Problems
Sample Answer
Requirements

Functional: advertisers set a daily budget per campaign; ad servers decide whether a campaign may enter each auction; clicks are recorded, filtered for invalid activity, and billed; reports show s...

High-Level Design
  1. Ad servers run auctions with a local in-memory view of each campaign's pacing state: remaining budget slice and a throttle probability.
  2. Spend events (clicks, or impressions for CPM) flow...

Submit Your Answer
Markdown supported