Design WhatsApp

Problem Design a WhatsApp-style messaging system supporting 1:1 and group chats — covering both the high-level design and selected LLD details.

Functional requirements

  • Send/receive messages 1:1 and in groups; delivery states (sent/delivered/read).
  • Message history/sync across a user's devices; offline delivery on reconnect.

Non-functional requirements

  • Scale to discuss: 1B+ users, tens of billions of messages/day; delivery latency < ~200 ms online.
  • No message loss (at-least-once + dedupe); end-to-end encryption.

Areas to go deep

  • The persistent-connection layer and user-to-gateway routing.
  • Message storage/sequencing and group fan-out.
  • Offline delivery, per-recipient retry, and E2EE implications.
asked …
LeaderboardSalaryAccount