Keeping live streams alive
RTMP relies on persistent TCP connections, which makes live streaming vulnerable to network interruptions. When a connection drops, data is lost until the client establishes a new session—a process that can take up to 20 seconds. RTMP Go Away introduces a mechanism for servers to notify clients of an impending disconnect, allowing the client to reconnect at a clean media boundary with zero data loss.
How the signaling works
The mechanism extends the existing RTMP specification in two key ways:
- Feature negotiation: A new field in the RTMP connect packet lets a client announce that it supports the go away signal.
- New message type: A dedicated protocol message represents the go away signal itself, enabling servers to notify capable clients about an upcoming connection termination.
The approach also includes a reference implementation in FFmpeg that demonstrates how a client can respond to the signal. Upon receiving it, the client reconnects at the next keyframe, avoiding data loss during the transition.
To ensure a safe rollout, servers only send the go away message to clients that have explicitly indicated support for the feature during the initial handshake. This prevents legacy clients from receiving messages they cannot interpret.
Why this matters for broadcasters
Unplanned server-side interruptions—such as host maintenance—have historically caused measurable data loss for live events. Without a go away mechanism, clients must detect a dead connection on their own, which can take up to 20 seconds of lost content. RTMP Go Away turns a known interruption into a coordinated transition, allowing the client to switch servers gracefully at a logical boundary instead of suffering an abrupt cut.
The specification and reference client are available on GitHub.



