Manually configure encoders for live event streaming in Microsoft Stream
If you have an encoder that is not directly integrated into Microsoft Stream, learn how to setup and configure the encoder manually for Live streaming with Microsoft Stream.
Microsoft Stream accepts live feeds from a variety of different encoders that output RTMP or RTMPS. Each encoder is different, so make sure to follow the guidelines for the encoder configurations when sending to Stream. Check out the list of tested encoders with easy setup to get started.
To learn how to setup a Live event in Microsoft Stream, read about creating live events. If you are already using an encoder that is integrated with Microsoft Stream, read about configuring encoders for live streaming.
After you save the live event (read Creating live events for details), you can see the list of integrated encoders in the Select encoder drop down list on the Encoder setup tab. The ingest URLs are also generated at this time. Select Configure manually to setup an encoder not in the list of integrated encoders.
Select Start setup to create an ingest channel for live streaming. Wait for the setup to be complete. You will see a Ready to connect message on the screen.
Copy and paste the following settings into the encoder of your choice:
a. Server ingest URL: In your encoder, this may be called URL or Address. Microsoft Stream does not require a stream key or name, so you can fill this in with any non-empty value such as MicrosoftStream.
b. Secondary server ingest URL: If supported by your encoder, use this URL to double push to improve durability and resiliency. Since this is outputting a redundant stream from your encoder, it will require double bandwidth. So, make sure that you have the required bandwidth capacity to support this. This is listed under the advanced section.
c. Use the Secure Connection (SSL) toggle to switch between RMTP or RTMPS protocols for the ingest URLs. Note that your encoder must support RTMPS to use it.
Microsoft Stream does not require a stream key or name, so you can fill this in with any non-empty value such as, MicrosoftStream. Depending on the encoder, this may be entered on a separate field or appended to the end of the ingest URL e.g. /MicrosoftStream.
Make sure your encoder is configured with the correct settings as per our recommended encoder settings below.
Configure your encoder with the desired audio and video sources.
Start streaming from your encoder to the Microsoft Stream ingest endpoints.
Go back to Microsoft Stream. After you are able to see the preview from the encoder, select Start event to go live so your audience can see the live event.
Recommended encoder settings
- Single bitrate RTMPS or RTMP
- Codec: H.264
- Profile: High (Level 4.0)
- Bitrate: Up to 5Mbps (5000 kbps)
- Strict Constant Bitrate (CBR)
- Keyframe/GOP: 2 seconds
- There must be an IDR frame at the beginning of each GOP
- Frame Rate: 29.97 or 30fps
- Resolution: 1280 x 720 (720P)
- Interlace Mode: Progressive
- Pixel Aspect Ratio (PAR): Square
- Codec: AAC (LC)
- Bitrate: 192 kbps
- Sample Rate: 48 kHz or 44.1 kHz (recommend 48 kHz)
- Both an audio and video stream must be present in order to playback content in Microsoft Stream.
Whenever possible, use a hardwired internet connection.
A good rule of thumb when determining bandwidth requirements is to double the streaming bitrates. While this is not a mandatory requirement, it will help mitigate the impact of network congestion.
When using software based encoders, close any unnecessary programs.
Don't change your encoder configuration after it has started pushing. It has negative effects on the event and can cause the event to be unstable. If you want to do this before the event has started, you must disconnect using the producer controls in Microsoft Stream and start setup again.
If the encoder is disconnected during the live event, reconnect it keeping the same timestamps of continuing process. Note that any discontinuity may cause audio or video issues on certain browsers and devices.
Give yourself ample time to setup your event. For high scale events, its recommended to start the setup an hour before your event.