MoQ is under active development. APIs and protocols may change between releases.

Skip to content

Concepts ​

MoQ is a stack of small layers. A relay only needs the middle one, which is what lets it forward media it can't parse.

LayerRoleImplemented by
ApplicationYour product: rooms, auth, custom tracks.You
hangMedia: a catalog of tracks, codec config, timestamped frames.hang, @moq/hang
moq-liteGeneric live pub/sub: broadcasts, tracks, groups, frames.moq-net, @moq/net, relays, CDNs
TransportQUIC streams, via WebTransport in browsers, with a WebSocket fallback.The browser, moq-tokio

The model in one paragraph ​

A broadcast is a named, discoverable collection of tracks from one publisher. A track is a live sequence of groups, and each group is a sequence of frames delivered reliably and in order over its own QUIC stream (or, for a tiny single frame, as one unreliable datagram). Groups are independent: they can arrive out of order, be prioritized against each other, and be dropped under congestion without corrupting the rest. For video a group is a GoP starting at a keyframe; for audio it's a second or so of samples; for data it's whatever unit can be skipped as a whole.

Subscribers pull. Nothing is transmitted until someone subscribes, duplicate subscriptions are merged at every relay on the way upstream, and a publisher that watches demand (the capture and transcode paths do) can skip encoding too. Each subscriber also chooses its own latency budget, so the same broadcast can be watched at 100 ms by one viewer and 10 s by another.

Sections ​

  • Transport: why QUIC, and the WebTransport, WebSocket, raw QUIC, and iroh paths onto it.
  • moq-lite: the pub/sub protocol, discovery, path patterns, subscriptions, and congestion behavior.
  • hang: the media catalog, containers, and how to extend both.
  • Audio jitter: how a receiver sizes its audio playout target from arrival timing.
  • Stats: the traffic counters a relay publishes as broadcasts, and how to read them.
  • Standards: how this relates to the IETF moq-transport, MSF, LOC, and this project's own drafts, including e2ee.
  • Use cases: MoQ compared with HLS/DASH, RTMP/SRT, WebRTC, and used for AI.

Licensed under MIT or Apache-2.0