System design interview questionMediumBasic System Component

Design a Gaming Leaderboard

Design a gaming leaderboard: submit scores and fetch top-N ranks fast.

Interview scope

Client → LB/Gateway → App → Cache (hot ranks) + DB (durable scores). No Client → Cache/DB.

Functional requirements

  • Submit or update a player’s score.
  • Return top-N leaderboard quickly.
  • Optional: fetch a player’s own rank.

Scale and quality goals

  • Reads of top-N must be very fast.
  • Score updates can be frequent during peak events.
  • Hot ranking data belongs in cache, not only cold SQL scans.

Capacity assumption

Design for this scale

Assume ~1M score updates/day and ~50M top-N reads/day (~12 RPS write, ~580 RPS read average).

Practice more than a diagram

Place components on the Froquiz canvas, connect the data flow, and see which decisions the scenario-specific review finds missing. The full exercise and review unlock with Premium.

Explore Premium