PracHub
QuestionsPremiumCoachesLearningGuidesInterview Prep
|Home/System Design/Pinterest

Design a high-throughput distributed rate limiter

Last updated: Mar 29, 2026

Quick Overview

This question evaluates distributed systems architecture, rate-limiting algorithms, data modeling, sharding and hot-key mitigation, consistency and fault-tolerance strategies, API design, and operational capacity planning within the System Design domain.

  • hard
  • Pinterest
  • System Design
  • Software Engineer

Design a high-throughput distributed rate limiter

Company: Pinterest

Role: Software Engineer

Category: System Design

Difficulty: hard

Interview Round: Onsite

Design a high-throughput distributed rate limiting service that supports per-user and global limits with burst tolerance and an approximately sliding window. Target 10M requests/second at peak across multiple regions. Specify the API, choice of algorithms (token bucket, leaky bucket, sliding window), data model, sharding and hot-key mitigation (e.g., consistent hashing, key splitting), storage choices (in-memory vs. Redis vs. custom), replication, and time coordination. Explain how you enforce limits on the request path, handle failures and partial outages, ensure fairness, and provide eventual or strong consistency where needed. Show how you would scale out: capacity planning formulas, how many machines to add for a 2× traffic spike, autoscaling signals, and backpressure/throttling strategies.

Quick Answer: This question evaluates distributed systems architecture, rate-limiting algorithms, data modeling, sharding and hot-key mitigation, consistency and fault-tolerance strategies, API design, and operational capacity planning within the System Design domain.

Related Interview Questions

  • Design a Distributed Rate Limiter - Pinterest (medium)
  • Design Catalog Update Pipeline - Pinterest (medium)
  • Design an ads event reporting system - Pinterest (medium)
  • Design autocomplete and merchant bulk edits - Pinterest (medium)
  • Design highly available blob storage service - Pinterest (medium)
Pinterest logo
Pinterest
Sep 6, 2025, 12:00 AM
Software Engineer
Onsite
System Design
10
0

System Design: High-Throughput Distributed Rate Limiting Service

Context

You are designing a multi-tenant rate limiting platform for an edge/gateway layer that protects downstream services. The system must enforce both per-user and global limits, tolerate bursts, and approximate a sliding window across multiple regions at peak 10M requests/second.

Requirements

Design a distributed rate limiting service that:

  • Supports per-user and global limits with burst tolerance and approximately sliding-window semantics.
  • Handles 10M RPS peak across multiple regions with low latency.
  • Specifies:
    1. Public API (check, configure, introspect) and enforcement integration on the request path.
    2. Algorithms (token bucket, leaky bucket, sliding window) and why.
    3. Data model for counters/buckets/policies.
    4. Sharding and hot-key mitigation (e.g., consistent hashing, key splitting).
    5. Storage choices (in-memory vs. Redis vs. custom), replication, and time coordination.
    6. Failure handling and partial outages; fairness and consistency (eventual vs strong) where needed.
    7. Scale-out plan: capacity planning formulas, machines needed for a 2× traffic spike, autoscaling signals, and backpressure/throttling strategies.

Solution

Show

Submit Your Answer

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More Pinterest•More Software Engineer•Pinterest Software Engineer•Pinterest System Design•Software Engineer System Design
PracHub

Master your tech interviews with 8,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.