We have covered dozens of topics regarding live streaming so you can become a pro! With the help of our articles, you can learn how to properly set up your equipment, use a green screen, and become a Twitch affiliate. But now it’s time to tackle something a little bit more challenging to grasp — streaming protocols. What are those and why do we need them?
In this article, we will compare the most popular live streaming protocols and help you decide which one suits your needs the most. Basically, there’s no such thing as a “bad” streaming protocol. Although it may seem a bit complicated, in reality, you don’t need to have some specific education to understand video streaming protocols. This is exactly the point we are going to prove!
Understanding streaming protocols and the way they work
A streaming protocol is a specific method used to deliver multimedia across the web. In other words, it is a set of rules that regulates how data is transferred, as well as how to handle any errors that may occur during this process.
Let’s clear some things up. Firstly, a streaming protocol is not the same as a codec. The latter is a specific technology to make your data (for instance, a video file) smaller. Simply put, a codec deletes unimportant information in the video to compress the file size.
Secondly, some people confuse a streaming protocol with a container format, which basically means how the data is stored. For example, three of the most common package formats for streaming video files are FLV, MP4, and MPEG-TS.
Before we start describing the most popular streaming protocols, we need to mention one important aspect. There are seven logical layers, each serving specific communication functions. In order to simplify things, streaming protocols operate within these layers to focus only on their functions. Okay, this doesn’t get any more difficult, so bear with us.
TCP vs. UDP
One layer in particular deserving your attention is the transport layer. It is responsible for the transmission of your content to the end platform. There are two ways it can be transmitted — via the Transmission Control Protocol (TCP) or the User Datagram Protocol (UDP). The main difference between these two is TCP forces the communicating devices to establish a connection to transfer data. UDP, on the other hand, ignores this step.
On a more practical level, UDP transmits small bits of information relatively faster than TCP. However, this comes with a price. Due to the absence of multiple handshakes and confirmation steps between the devices, the data can’t be transmitted in a strict order. Moreover, the receiving side may not get some pieces at all. This can sometimes result in minor issues with the quality.
Most-used streaming protocols
Clearly, there are dozens of live streaming protocols, each serving its purpose. However, we can certainly single out the few most popular ones.
RTMP (Real Time Messaging Protocol): TCP
Developed by Macromedia and acquired by Adobe in 2005, RTMP still remains the most-used protocol. It maintains a persistent, stable connection and allows for low-latency communication. RTMP transfers stream data that is split into small packets between Flash Player and a server to ensure minimal interruptions and artifacts. Also, because of the legacy factor, RTMP is supported by most streaming platforms and software.
This protocol’s specifications were officially released by Adobe for public use. Ironically, the company announced it would stop supporting Flash Player. Another disadvantage of RTMP protocol is the possibility of interruptions due to low bandwidth up to the point where your stream might not start at all. Adding to the list of cons, some tight firewalls might not allow RTMP connections due to the low security of delivering videos. Although, we have to say this happens quite rarely.
Adding to the list of cons, the standard stream delay is around five to 30 seconds, but it can be lowered to two or three seconds. Also, the protocol currently uses the H.264 video codec and AAC audio codec, which are rather old and do not provide the best quality.
- Video codecs: H.264
- Audio codecs: AAC
- Latency: 3 - 30 seconds
Pros: Multicast support, low buffering, wide platform support
Cons: Old codecs, somewhat low security, relatively high latency
WebRTC (Web Real-Time Communication protocol): both UDP and TCP
WebRTC is an open-source standard for real-time communications supported by nearly every modern browser, including Safari, Google Chrome, Firefox, Opera, and others. WebRTC supports high-quality VP8 and VP9 (besides the old H.264), as well as the Opus audio codec. In the near future, the protocol will gain support for a brand new AV1 video codec. The protocol is predicted to replace telephony and become the pillar of communication services.
One of the biggest advantages of WebRTC is that it transforms millions of browsers into streaming terminals without any additional plugins needing to be installed. Moreover, WebRTC supports sub-second latency, which means no more delays! Lastly, the protocol uses an adaptable bit rate technology, which allows it to automatically adjust video quality and prevent any drops and interruptions.
As for the drawbacks, WebRTC doesn’t have many. Some would consider the fact that the protocol is still under development a minus. Others may find the danger in the codecs it uses. How come? Simply put, the VP8 codec is royalty-free, while H.264 is not. Although most companies are in favor of VP8, some others are strongly against this decision, which might result in a conflict. However, it is worth mentioning that everyone agrees AV1 is the future.
- Video codecs: VP8, VP9, H.264 (H.625 + AV1 in progress)
- Audio codecs: Opus
- Latency: Less than one second
Pros: No plugins needed, sub-second latency, supported codecs
Cons: Instability due to sub-second latency
FTL (Faster Than Light protocol): UDP
Update: FTL was developed by the streaming platform Mixer, owned by Microsoft. Unfortunately, Mixer was shut down due to inability to scale in comparison with its competitors. However, we believe the understanding of this protocol can be useful. Therefore, we keep the information about the technology.
FTL’s name surely speaks for itself. FTL is a real-time streaming protocol, which means it supports sub-second latency. This allows you to engage and communicate with your viewers in real time with virtually no delay. FTL is supported by the most popular streaming applications, including XSplit and OBS Studio. It is also pre-integrated into the Windows 10 OS and Xbox One. It uses the Opus audio codec and the H.264 video codec to allow for a good mix of quality, smooth playback, and low latency.
The downside of using FTL is that your stream will lose quality a bit. Mixer recommends lowering your bitrate to 7 Mbps in comparison to the RTMP’s 10 Mbps. Another of FTL’s disadvantages is a lack of stability. Unlike its ancestors, the FTL protocol hasn't yet gone through a lot of bug fixes, which means it can be a bit unpredictable. Even though FTL is brand new, it is already fully integrated into the Restream ecosystem. So far, only Mixer and Restream support the FTL protocol.
- Video codecs: H.264
- Audio codecs: Opus
- Latency: Less than one second
Pros: Ultra-low latency and real-time communication
Cons: Lower video quality, instability due to sub-second latency, weak support
SRT (Secure Reliable Transport): UDP
SRT is an open-source video streaming protocol developed by Haivision and Wowza. It is widely considered to be a substitute for RTMP in the near future. Sharing the same advantages, SRT is taking the next step and making the dream of stable live streams with a sub-second latency a reality. It allows you to live stream your content over suboptimal networks. One big drawback, however, is that the playback option is unavailable.
The developers state that SRT protects your live videos from jitters, bandwidth fluctuation, and packet loss. Moreover, SRT is similar to FTL and WebRTC in terms of sub-second latency, which allows for nearly real-time communication. Additionally, it is also stated that the protocol is codec-agnostic, meaning it supports any modern video and audio codec. Unfortunately, considering it is still an emerging technology, SRT is not widely supported.
- Video codecs: Codec-agnostic
- Audio codecs: Codec-agnostic
- Latency: Less than one second
Pros: High quality, stability, sub-second latency, strong codec support
Cons: Weak platform support, no playback
Video streaming protocols comparison
Let’s wrap up everything!
As you can now see, streaming protocols are tough to understand. Basically, a streaming protocol is a set of rules that determines how data is transferred over the internet. We’ve overviewed the four most popular live streaming protocols, which are RTMP, WebRTC, FTL, and SRT. Each has its own pros and cons, meaning you can use any one depending on your needs. You can, however, simply use Restream.io and stop racking your brain over this technical stuff.
Lastly, we want to make some predictions. It seems quite obvious that the good old RTMP is going to meet its demise sooner or later. SRT is going to compete with FTL for the championship rings. Meanwhile, slowly but surely, WebRTC will grow and transform into the ultimate streaming protocol and will dominate the market eventually. This is just a bald prediction, so don’t take our word for it. Maybe we are completely wrong, and SRT will take it all one day!