Web Player

Updated at:
Copy as MD

The ApsaraVideo Player SDK for Web can be integrated into your web application to enable video playback for live streaming and video on-demand (VOD).

Important

For more information about the features of the web player, see Web Player.

Online demo

Follow the steps in Get started with ApsaraVideo Live to start a live stream, and then enter the streaming URL to preview the playback in the web player.

Note
  • The web player requires HTTPS to play a streaming URL. For information about certificate application and HTTPS configuration, see HTTPS settings.

  • The web demo does not support playing live streams over the RTMP protocol. Use playback URLs in FLV or M3U8 format.

  • When you play videos using FLV or M3U8 playback URLs, your browser may report a cross-origin error. To resolve this issue, configure HTTP headers for your streaming domain. For example:

    • Access-Control-Allow-Origin: *

    • Access-Control-Allow-Methods: GET,POST,PUT,Delete,Option

Procedure

  1. Follow the steps in Get started with ApsaraVideo Live to start a live stream and obtain the streaming URL.

  2. Go to the web demo and select Online Settings from the top menu bar.

  3. Switch to the Basic tab, select a Video Type, and enter the URL.

  4. Switch to the Preview tab to check if the live stream plays correctly.

    The live stream plays correctly when video appears in the player and a LIVE indicator is displayed in the lower-left corner.