Design Microsoft Teams

Hard45 min
1 / 30
System design answer

Design Microsoft Teams

Hard45 min30 sections
understanding•10 min read

Problem Statement: An Enterprise Real-Time Collaboration Suite

Frames Teams as four distinct planes — messaging, presence, media, and compliance — each with a different consistency, latency, and failure model.

Problem statement

Design an enterprise real-time collaboration platform equivalent to Microsoft Teams: persistent channels and group chats, one-to-one and group messaging with reactions and edits, multi-party audio and video meetings with screen sharing, real-time presence, file sharing and co-authoring, calendar-integrated meeting scheduling, bots and third-party app add-ins, and enterprise compliance — eDiscovery, retention policies, data-loss prevention, and legal holds.

This is not one system. It is at least four systems that share an identity and tenant model. The messaging plane is an eventually consistent, fan-out-heavy, durable workflow. The presence plane is a high-churn, coalesce-friendly, freshness-bounded projection. The media plane is a latency-critical, loss-tolerant, regional routing problem where packets matter more than records. The compliance plane is an append-only, strongly audited capture system that must observe every other plane without degrading them.

Why the problem is distinctive

A consumer chat app can lose a message and survive. An enterprise suite cannot lose a message that is under legal hold, cannot leak one tenant's data into another tenant's query, and cannot let a 500,000-seat tenant's channel post starve the rest of the platform. The hard part is not any single feature; it is the coexistence of contradictory requirements: delivery that feels instant, durability that survives region loss, fan-out that scales to enormous channels, and compliance capture that is complete even when everything else degrades.

Message delivery is retriable. A live video frame is not — late video is dropped, not replayed. Presence is never retried at all — only the newest value matters. Compliance capture is never dropped — it is the one consumer allowed to slow everything else down rather than lose data. A strong answer separates these delivery contracts explicitly instead of claiming the whole platform is 'eventually consistent'.

Public operating baseline versus design assumptions

Public evidence establishes that the category operates at massive scale. Microsoft reported 320 million monthly active Teams users at Ignite in November 2023, after reporting 145 million daily active users in April 2021, and a peak of 200 million meeting participants in a single day in April 2020. Discord reported roughly 200 million monthly active users in 2023 and has published detailed engineering accounts of migrating a trillion-message store from Cassandra to ScyllaDB. Slack reported 32 million daily active users in 2021 and has published accounts of Kafka-based message pipelines over sharded MySQL (Vitess). Zoom reported 300 million daily meeting participants in April 2020. These are company-reported figures used for context, not requirements for our fictional system.

For capacity planning, this answer explicitly assumes a mature platform with 250 million monthly active users, 60 million daily active users, 25 million concurrently connected users at peak, 3 billion message events per day, 18 million meetings per day, and a five-times event peak. Unless a number is tied to a citation, it is a stated design assumption, target, or illustrative threshold.

The four architectural planes

  1. Messaging plane: durable conversation store, per-user delivery and sync, reactions, edits, deletes, mentions, unread state, offline catch-up.
  2. Presence and notification plane: derived availability state, watcher fan-out with aggressive coalescing, push and in-app notification routing.
  3. Media plane: signaling, SFU-based conferencing, simulcast, congestion control, recording, PSTN-adjacent gateways out of scope.
  4. Compliance and collaboration plane: capture journal, retention and legal hold enforcement, eDiscovery export, files and calendar integration through document and calendar services.

A strong interview answer keeps these planes separate. It lets the presence plane degrade to stale data without weakening message durability, lets media reroute around a failed relay without touching the message store, and lets compliance lag in projection while never losing an event.

Key Highlights

  • •Teams is four systems: messaging, presence, media, and compliance — each with its own consistency and failure contract.
  • •Messages are durable and retriable; media frames are ephemeral and droppable; presence is last-write-wins; compliance capture is never dropped.
  • •Public fleet figures (320M MAU Microsoft-reported) provide context; every uncited scale number here is an explicit assumption.
  • •Tenant isolation is a first-class invariant, not a WHERE clause afterthought.
  • •The hidden scaling problem is fan-out multiplication: presence watchers, channel members, and notification recipients — not message intake QPS.
Lead With the Plane Separation
State in the first two minutes that messaging, presence, media, and compliance have different consistency and loss semantics. This instantly distinguishes an enterprise RTC architecture from a generic chat app.
Do Not Draw One Queue for Everything
A single event bus carrying messages, presence heartbeats, and media signaling fails under presence churn and head-of-line-blocks compliance capture. Separate topics, priorities, and retention are mandatory.

Section Rescue Kit

Buzzwords to use:

Delivery ContractTenant Isolation Boundary

Safe statements:

  • "I will separate delivery completion from real-time media: the former may retry, the latter may drop."
  • "Before selecting services, let me define which plane owns each decision and what its failure looks like."
Design Microsoft Teams - System Design | WinJob | WinJob