MID stands for Media Identification.
In WebRTC SDP, the MID attribute (a=mid) uniquely identifies each media description (m= line) within a session. It is essential for BUNDLE multiplexing, where all media shares a single transport.
How MID works
When multiple media streams are bundled over one connection:
- Each m= line in the SDP gets a unique MID value (e.g., “0”, “1”, “2” or “audio”, “video”)
- The MID is included as an RTP header extension in media packets
- The receiver uses the MID to demultiplex incoming packets and route them to the correct media track
MID in Unified Plan
In Unified Plan SDP (the current WebRTC standard), every track gets its own m= line with a unique MID. This enables:
- Adding/removing individual tracks without renegotiating the entire session
- Identifying specific tracks in SFU forwarding scenarios
- Associating RTCP feedback with specific media streams
See also: RID (for simulcast layer identification), SSRC (for stream identification)


