How to publish with OBS
OBS (Open Broadcaster Software) is a free and open source video recording and live streaming software. With OBS, you can use either your PC's embedded camera or an externally connected camera as a video source. Audio sources can also be set up.
Let's go over how to use OBS for streaming step by step:
Install the OBS
Download Open Broadcaster Software from obsproject.com and install it.
Launch OBS. By default, OBS begins capturing from your built-in camera if one is present. In the Sources section, you can add or remove video/audio sources.
We assume that your Ant Media Server accepts all streams (e.g there is no security option enabled.)
Settingsin the OBS Window and then Select
Streamon the left side menu.
Custom Streaming Serverin the
Stream Typedropdown menu.
- In the URL box, type your RTMP URL without stream id. It's like
- In the Stream key, you can write any stream id because we assume that all stream Ids are allowed.
The RTMP URL should not contain any port number. The RTMP protocol will automatically listen on port 1935 which should be open on your server.
- Wrong: rtmp://am.streamomedia.com:5443/WebRTCAppEE/
- Correct: rtmp://am.streamomedia.com/WebRTCAppEE/
Note: When you use tokens you need to generate a publish token and use it in this format inside the stream key :
Tune for ultra-low latency streaming
OBS is not optimised for ultra-low latency streaming by default. If you use OBS to push an RTMP stream and play it with WebRTC, please go to
Settings > Output and make the rate control
CBR (Constant Bitrate) and tune for
zerolatency. You can also adjust the bitrate to meet your quality and internet bandwidth requirements. Furthermore, the
keyframe interval should be set to 1. Please see the screenshot below for reference:
Please keep in mind that if your network isn't stable enough to send the requested bitrate all of the time, you may experience freezes while watching the stream.
Settings window and just click the “Start Streaming” button in the main window of OBS.
Congrats! You're publishing a live stream with OBS.
If you are experiencing stream quality issues, you should check the following indicators in OBS.
Stream health parameters are located at the bottom right. There are 3 stream health parameters:
Stream health color.
- Dropped frames: This value should be 0. If it increases, you may decrease your FPS or bitrate parameters in OBS settings.
- CPU: CPU value is important for streaming quality. We recommend that it never exceeds 70%.
- Stream health color: This color should be green. If it has a color between yellow and red you may have problems with your stream quality.
OBS encoding overloaded warning
If your PC cannot handle the stream with the parameters you set, this warning appears. In this case, you may want to decrease the resolution, bitrate, or change the encoder preset value to one with high speed and low quality.