Mock Interviewer
Ask Coach
Tap a question to start, or type your own below.
Twitter System Design
Visual Problem Diagram

Scenario
A celebrity posts and 50M followers would each need a mailbox write if you fan out naïvely—your queue depth explodes while timelines for normal users still need < 300 ms loads. The interview is fan-out on write vs pull on read, timeline ranking, and tweet id pagination—not drawing the bird logo.
Design a microblogging platform where users post tweets, follow others, and read a personalized home timeline. The hard part is asymmetric fan-out: most users are cheap to push-update, but celebrities break naive O(followers) writes per tweet.
You should support tweet creation, follow graph, timeline generation, search/trending hooks, and media attachments. Be ready to explain hybrid fan-out, tweet ID design, timeline pagination, and read-heavy scaling. Deletion and consistency of timelines are fair follow-ups.
Constraints
Post/delete tweet, follow/unfollow, home timeline, user profile timeline, media attachments, search/trending hooks
< 300 ms p95 timeline load, high availability, timeline eventual consistency in seconds, durable tweets
300M MAU, 500M tweets/day, timeline reads orders of magnitude higher than writes; accounts to 100M+ followers
Stages ahead
Log in to start practicing
Preview the problem below. Sign in to start your timed session, save progress, and use the AI coach.