hls.js is a widely used JavaScript library that implements HLS playback on top of MSE, enabling HLS in browsers (Chrome, Firefox, Edge) that do not support it natively. Since HLS is otherwise only native to Safari, hls.js is what makes HLS a truly cross-browser format on the web.

It handles manifest parsing, ABR, buffering, and error recovery, and integrates with EME for DRM. Many platforms standardize on HLS for all devices and use hls.js for desktop and Android browsers while letting Safari and iOS use native HLS - a common pattern that simplifies packaging to a single protocol while still covering every browser.