Main principles

Real Time Messaging Protocol (RTMP) is the most common way to stream to video streaming platforms:
  • Used primarily for receiving an origin stream from your encoder, not for playback.
  • Default port: RTMP 1935 (TCP), RTMPS 443 (TCP).
  • Must be configured on your encoder with parameters provided in the Input Parameters and Codecs.
Gcore Live Streaming supports both RTMP and RTMPS. RTMPS wrapped in TLS for encrypted transport, which helps traverse restrictive firewalls.
RTMP only supports H.264 video + AAC audio; for other codecs (e.g. H.265/HEVC), use use SRT ingest.We plan to support H265/HVEC and other extensions from the Enhanced RTMP specification. Stay tuned for updates.

PUSH streams

Use RTMP PUSH when the encoder itself can establish an outbound connection to our Streaming Platform. This is the best choice in situations like:
  • Use software encoders like OBS, ffmpeg, etc,
  • use hardware encoders like Elemental, Haivision, etc,
  • and when you control the encoder, want the simplest workflow, and don’t want to maintain your own always-on origin server.
Your encoder settings should contain the exact ingest parameters: server URL, backup URL (if used), stream key. Read below how to get ingest links. To use RTMPS, just manually change the protocol name from rtmp:// to rtmps://. Ingest link is looks like rtmp://vp-push-ed1.gvideo.co/in/12345?aaabbbcccddd and contains:
  • protocol rtmp:// or rtmps://
  • name of a specific server located in a specific geographic location – vp-push-ed1 is located in Europe
  • exact stream key 12345?aaabbcccddd
Example: That ffmpeg command will generate a test video (1280×720 @30fps color bars) with a 2kHz sine-tone audio track, encode them to H.264 video + AAC audio, and push the stream in FLV format over RTMP to the specified ingest URL.
ffmpeg -re -f lavfi -i testsrc2=size=1280x720:rate=30 \
       -f lavfi -i sine=f=2000:r=48000 \
       -c:v libx264 -preset veryfast -b:v 1M -g 30 \
       -c:a aac -b:a 128k -ar 48000 \
       -f flv "rtmp://vp-push-ed1.gvideo.co/in/12345?aaabbbcccddd"
If the stream is experiencing transcoding or playback problems, then perhaps changing the ingest server to another location will solve the problem. Read more in the Geo Distributed Ingest Points section, and contact our support to change the ingest server location.

Obtain the server URLs and stream key

There are two ways to obtain the server URLs and stream key: Customer Portal UI or API.

Via UI

  1. In the Gcore Customer Portal, navigate to Streaming > Live Streaming.
List of live streams
  1. Click on the stream you want to push to. This will open the Live Stream Settings.
Live stream settings
  1. Ensure that the Ingest type is set to Push.
  2. Ensure that the protocol is set to RTMP or RTMPS in the URLs for encoder section. 5. Copy the Server URL and Stream Key from the URLs for encoder section.
URLs for encoder section

Via API

You can also obtain the URL and stream key via the Gcore API. The endpoint returns the complete URLs for the default and backup ingest points and the stream key. Example of the API request:
GET /streaming/streams/{stream_id}
Example of API response:
{
  "push_url": "rtmp://vp-push-anx2.domain.com/in/123?08cd54f0",
  "backup_push_url": "rtmp://vp-push-ed1.domain.com/in/123b?08cd54f0",
  ...
}
Read more in API documentation.

PULL streams

Gcore Video Streaming can PULL video data from your origin. Main rules of pulling:
  • The URL of the stream to pull from must be publicly available and return data for all requests.
  • If you need to set an allowlist for access to the stream, please contact support to get an up-to-date list of networks.

Setting up a PULL stream

There are two ways to set up a pull stream: via the Gcore Customer Portal or via the API.

Via UI

  1. In the Gcore Customer Portal, navigate to Streaming > Live Streaming.
List of live streams
  1. Click on the stream you want to pull from. This will open the Live Stream Settings.
Live stream settings
  1. Ensure that the Ingest type is set to Pull.
  2. In the URL field, insert a link to the stream from your media server.
  3. Click the Save changes button on the top right.

Via API

You can also set up a pull stream via the Gcore API. The endpoint accepts the URL of the stream to pull from. Example of API request:
PATCH /streaming/streams/{stream_id}
{
  "stream": {
    "pull": true,
    "uri": "rtmp://example.com/path/to/stream",
    ...
  }
}
Read more in API documentation.

Primary, Backup, and Global Ingest Points

In most cases, one primary ingest point with the default ingest region is enough for streaming. For those cases where more attention is needed, Streaming Platform also offers a special feature to use backup ingest point and specify another explicit ingest region. For example, if you are streaming from Asia and latency seems too big or unstable to you. For more information, see Primary, Backup, and Global Ingest Points

Ingest Limits

Only one ingest protocol type can be used for a live stream at a time. For example, if you start pushing RTMP and then try to push another protocol like WebRTC WHIP to the same stream simultaneously, the transcoding process will fail.

RTMP/S Troubleshooting

ErrorCauseSolution
Inappropriate codec for RTMPOnly H.264 and AAC are compatible
  • Only H.264 codecs for video and AAC for audio are suitable for RTMP, while other codecs H.265/HEVC, AV1, MP3, Opus, etc are not suitable because they do not fit into the native RTMP protocol format.
  • Check the video and audio ouput codecs in your encoder for RTMP output.
  • Enhanced RTMP is not supported yet.
SSL issuesYou used rtmps:// but in the encoder rtmp:// is specifiedCheck the protocol in your encoder.
Follow step 3 of the guide.
You used a port (80) unsuitable for secure data transferManually add the correct port (443) to the server link, e.g.:
rtmps://vp-push-ed1.gvideo.co:443/in/
No transcoding or image degradation when using web cameras with custom video codecsThe video codec H264+ extension has an over-increased keyframeCheck the outgoing live stream parameters of the web camera:
  • Streams must be encoded using H.264 — no custom codecs like H264+ allowed.
  • “Smart” codec modes must be turned off.
Web camera codec settings
“Connection timed out”The server URL is incorrectCheck the server URL in the encoder settings.
Ensure the protocol is rtmps://.
Your encoder doesn’t support RTMPSVerify whether your encoder supports RTMPS.
If not, consider switching to one that does.