How to play an m3u8 file

How to play an M3U8 file

An .m3u8 file is a text playlist, not a video. Playing it means giving an HLS-capable player the playlist URL and letting it fetch the segments listed inside, which is why the same link behaves differently in Safari, in Chrome and in VLC.

There are three routes that work, and which one you need depends on the device and on whether you control the page the video appears on.

Start Free

What you are actually opening

The file begins with #EXTM3U and lists either variant playlists (a master playlist) or media segments with their durations (a media playlist). The video itself lives in the .ts or .m4s files the playlist points at. Opening the playlist in a text editor shows you those instructions; it will never show video.

So "playing an m3u8 file" always means "handing the playlist URL to something that speaks HTTP Live Streaming". The three routes below are three such things.

Three ways that work

  1. Paste the URL into a browser player

    The online M3U8 player takes a playlist URL, plays it in the page and reports the real error when it fails. Nothing gets installed and nothing gets uploaded. The stream server has to allow cross-origin reads, because the page isn't on the same origin as your stream.

  2. Play it natively in Safari, QuickTime or VLC

    Apple platforms ship an HLS decoder, so opening the .m3u8 URL in Safari, or opening the URL in QuickTime Player, plays it with no page involved. VLC on any desktop does the same. This route isn't subject to the browser CORS rule, which is why it often works on a stream that fails in a web page.

  3. Embed it in your own page

    A video element plays HLS natively on Safari and iOS. Chrome, Edge and Firefox need a player library that uses Media Source Extensions, such as hls.js or the Bradmax player. The embed guide has copy-paste snippets for both, and the CORS note that explains most failures.

Which route works on which device

Native HLS means the platform decodes the playlist itself, with no library and no page.
Device or app Plays the URL natively What to use
iPhone and iPad (Safari) Yes Open the URL, or a video element in a page
macOS Safari Yes Open the URL directly
QuickTime Player Yes File, Open Location, paste the URL
Chrome, Edge, Firefox on desktop No A player library (hls.js or Bradmax) or VLC
Android Chrome No A player library, or a native app
Windows (no browser) No VLC, or a player application
Smart TV browsers Usually Platform dependent, test on the target model

Why a downloaded .m3u8 file won't play

A playlist refers to its segments by relative path. A file sitting in your Downloads folder has no origin for those paths to resolve against, so a player that opens it locally finds nothing to fetch. The video isn't in the file. The playlist isn't broken and the download isn't incomplete; the stream simply lives on a server.

To inspect a downloaded playlist, use the HLS playlist inspector, which parses it, lists the variants, validates the tags and shows what the URLs inside point at. To play it, put the playlist and its segments on a server, then point a player at the URL.

If the URL still won't play

Almost every failure is one of five things, and each one is identifiable. A CORS block is the stream server not allowing the page to read it, and only that server can fix it. Mixed content is an http:// stream referenced from an https:// page, which the browser refuses. DRM is an encrypted stream that needs a licence before the first frame. A codec or packaging problem means the manifest is reachable but the segments use something the browser can't decode. A 404 means the playlist isn't where the URL says it is.

The online player names the case it hit instead of showing an empty box, and the playlist inspector separates a packaging problem from a playback problem. For the DRM case, the DRM capability tester reports which key systems this browser can actually use.

Frequently asked questions

How do I open an m3u8 file without installing anything?

Paste its URL into an online HLS player such as the Bradmax M3U8 player. The page plays the stream in your browser, and the stream server has to allow cross-origin reads for that to work. Nothing gets installed and nothing gets uploaded.

Why does an m3u8 URL show text instead of video?

Because a browser and a text editor both treat .m3u8 as a plain text file. The playlist is readable, but nothing in Chrome or Firefox decodes HLS by itself, so opening the URL directly shows the manifest. Safari decodes HLS natively, which is why the same URL plays there.

Does Chrome play m3u8 files?

Not natively. Chrome exposes Media Source Extensions instead, and an HLS player library such as hls.js or the Bradmax player uses that to feed the stream into a video element. Safari and iOS are the platforms with a built-in HLS decoder.

How do I play a downloaded .m3u8 file?

You can't play the file on its own in a browser: the playlist refers to segments by relative path, and a file on your disk has no server for those paths to resolve against. Use the playlist inspector to read and validate the file, or upload the segments to a server and play the playlist from there.

Why does the same m3u8 URL play in VLC but not in a browser?

VLC isn't a web page. It isn't bound by the browser rule that stops a page on one origin from reading data on another, so it plays streams whose server sends no Access-Control-Allow-Origin header. In a browser that case fails with a CORS error, which the online player reports instead of swallowing.