hls.js is a JavaScript library which implements an HTTP Live Streaming client. It relies on HTML5 video and MediaSource Extensions for playback.
It works by transmuxing MPEG-2 Transport Stream and AAC/MP3 streams into ISO BMFF (MP4) fragments. This transmuxing could be performed asynchronously using Web Worker if available in the browser. hls.js also supports HLS + fmp4, as announced during WWDC2016
hls.js does not need any player, it works directly on top of a standard HTML <video>
element.
Its official documentation can be found here.
For detailed instructions on how to implement the player, see How to use the hls.js player with Azure Media Service
For an implementation reference sample please check the following link which contains a complete implementation of a hls.js Player.
References:
-
✔️ All scenarios are supported in all tested browsers with both VOD and Live content (including Live Transcription and Low Latency).
-
⚠️ Some scenarios may not be supported (for more information, click more details at the bottom). -
❌ No scenario is supported.
Tested on:
- Chrome (v83.0.4103.97+)
- Firefox (v77.0.1+)
- Edge Chromium-based (v83.0.478.50+)
- Edge (v44.18362.449.0+)
Format | Clear | Token | Widevine | PlayReady | FairPlay | AES-128 | Captions |
---|---|---|---|---|---|---|---|
HLS TS | ✔️ | ✔️ | Not applicable | Not applicable | Not applicable | ✔️ | |
HLS CMAF | ✔️ | ✔️ | ✔️ | ❌ | Not applicable | ❌ |
Tested on:
Format | Clear | Token | Widevine | PlayReady | FairPlay | AES-128 | Captions |
---|---|---|---|---|---|---|---|
HLS TS | ✔️ | ✔️ | Not applicable | Not applicable | Not applicable | ✔️ | |
HLS CMAF | ✔️ | ✔️ | ✔️ | Not applicable | Not applicable | ❌ |
Tested on:
Format | Clear | Token | Widevine | PlayReady | FairPlay | AES-128 | Captions |
---|---|---|---|---|---|---|---|
HLS TS | ✔️ | ✔️ | Not applicable | Not applicable | Not applicable | ✔️ | |
HLS CMAF | ✔️ | ✔️ | ✔️ | Not applicable | Not applicable | ❌ |
Tested on:
Format | Clear | Token | Widevine | PlayReady | FairPlay | AES-128 | Captions |
---|---|---|---|---|---|---|---|
HLS TS | ✔️ | ✔️ | Not applicable | Not applicable | Not applicable | ✔️ | |
HLS CMAF | ✔️ | ✔️ | ✔️ | Not applicable | Not applicable | ❌ |
Tested on:
Format | Clear | Token | Widevine | PlayReady | FairPlay | AES-128 | Captions |
---|---|---|---|---|---|---|---|
HLS TS | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ |
HLS CMAF | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ |