☕ Buy Me Coffee
← Back to Feed

HLD: Design a News Feed (Twitter/X)

Twitter (News Feed) design must handle a massive imbalance: a celebrity tweet must be visible to millions instantly.

Fan-out on Write (Push)

For most users, when you tweet, we push it to the pre-computed "Home Feed" caches of all your followers. Optimized for blazing-fast reads.

Fan-out on Read (Pull)

For celebrities (millions of followers), pushing is too slow. Instead, their tweets are stored in a separate table, and followers pull them and merge into their feed only when they log in.

// FEEDBACK_LOOP.exe

0.0 / 5.0
FROM 0 PEERS
→ Login to rate