M3U, M3U8, and Xtream Codes: what's the difference?

When setting up an IPTV player, you'll often run into three terms: M3U, M3U8, and Xtream Codes. They tend to show up together, which makes them look like rival formats — but they aren't. M3U and M3U8 are files or playlists; Xtream Codes is a way to access and organize a service's data through an API. Each one serves a different purpose, and understanding that distinction clears up a lot of confusion.
Why these terms cause confusion
When you receive playlist data, it usually arrives in one of these forms: an M3U file or address; an address that ends in .m3u8; or a set of server, username, and password for access via Xtream Codes. All three can appear in the IPTV context, but they represent different things — a catalog file, a streaming playlist, and an API-based integration model.
What is M3U
At its core, M3U is a text file with a list of content and their respective addresses. In IPTV, it can gather live channels, movies, series, names, categories, logos, and the identifiers used by the EPG (the program guide). All of this usually comes in a single list, and it's up to the player to read, interpret, and organize that information.
An M3U snippet typically looks like this, where the first line marks the file and the following lines describe each channel and its address:
- #EXTM3U
- #EXTINF:-1 group-title="News",News Channel
- https://server.example/channel
What is M3U8
M3U8 is a playlist based on the M3U format, but it must be UTF-8 encoded — hence the extension. In streaming, it's closely associated with the HLS protocol. A .m3u8 URL can represent a specific channel or video, a list of video segments, different qualities of the same stream, or, in some services, a full content playlist.
With HLS, the player reads the M3U8 file and downloads small media segments in sequence. The protocol can also offer multiple resolutions and bitrates, letting the quality adapt to your internet speed.
Are M3U and M3U8 the same thing?
Not exactly, and this is an important point. Every M3U8 belongs to the M3U playlist family, but not every M3U file is an HLS stream. The .m3u8 extension simply indicates UTF-8 encoding. In everyday IPTV use, “M3U list” has become a generic name for any playlist, even when it contains M3U8 links. In other words, an M3U list can gather hundreds of channels, and one of those channels may point to a .m3u8 stream.
What is Xtream Codes
Xtream Codes is an integration model where you provide the server address, a username, and a password. Instead of downloading a single large list, the player queries endpoints of an Xtream Codes–compatible API. Through it, the app can receive separate data for live channels, categories, movies, series, seasons and episodes, account information, EPG, and playback URLs.
It's worth noting that today “Xtream Codes” is also used as a generic name for APIs compatible with that standard — not necessarily to indicate that the server runs the original software.
The main difference is how content is organized
This is perhaps the central point. The three options deliver content to the player in different ways:
- M3U: the player receives a linear list and has to interpret fields like name, category, and URL.
- M3U8: usually represents the technical structure of an HLS stream or a UTF-8 encoded playlist.
- Xtream Codes: the player queries more structured data, typically in JSON, receiving movies, series, categories, and episodes separately.
In practice, Xtream Codes tends to make it easier to build an interface similar to streaming services, precisely because the data already arrives organized.
How movies and series are identified
In an M3U list, the player often depends on clues like the group-title, the content name, the URL extension, and patterns defined by the provider. This can lead to errors, such as episodes classified as movies or series grouped incorrectly. In an Xtream Codes API, the server usually already tells whether an item is live TV, a movie, or a series, and can provide season, episode, cover art, synopsis, and other metadata.
What about performance?
A very large M3U list can take longer to download, process, split into categories, store locally, and update. With Xtream Codes, the app can query each section separately. That doesn't mean it will always be faster: performance also depends on the server, the player's implementation, caching, and the number of requests.
How content is updated
- With M3U, the player usually downloads the playlist again.
- With Xtream Codes, the player can re-query categories and content through the API.
- With the M3U8 of a live channel, the playlist is updated continuously to present new segments of the stream.
This contrast makes it clear that a catalog playlist and an HLS playlist serve quite different purposes.
Securing your credentials
Both an M3U URL and Xtream Codes access can contain sensitive information. A URL may include the username and password directly — for example, in an address shaped like “https://server.example/get.php?username=user&password=pass”. For that reason, avoid sharing configuration screenshots, playlist files, full URLs, or access credentials.
Player compatibility
- Some players accept only M3U.
- Others work with both M3U and Xtream Codes.
- Modern players may accept local files, remote URLs, and a separate EPG.
- Support for M3U8 HLS playback is very common on current platforms.
In the Apple ecosystem, HLS and M3U8 playlists have native support through technologies like AVPlayer, which makes playing this format feel natural on iPhone and iPad.
So which option is best?
There's no single answer — each option shines in a different scenario. M3U tends to be better when you want simplicity, want to import a single URL, need broad compatibility, or have a small, well-organized playlist.
Xtream Codes tends to be better when there are many movies and series, the player needs to separate categories, it's important to display seasons and episodes, or you want a more organized experience. M3U8, in turn, is most relevant when the subject is the technical playback of an HLS stream, with different video qualities, segment-based delivery, and quality that adapts to the connection.
Have an authorized M3U list or Xtream Codes access? See how Nebula Player reads both and organizes everything on your iPhone and iPad.
Discover Nebula Player
Thiago Monteiro
Creator of Nebula Player
iOS developer and creator of Nebula Player. Writes about how media players, authorized playlists, and streaming technologies work in practice.
Articles by Thiago MonteiroRelated articles

Is IPTV legal? What you need to know
Is IPTV legal or illegal? The answer depends on what's being distributed, not on the technology. Understand what copyright law says, who carries the most risk, and how to spot an unauthorized service before you subscribe.

IPTV buffering or freezing: why it happens and how to fix it
IPTV freezing at the worst moment? Learn what buffering really is, the path video takes to reach your screen, and how to find out whether the bottleneck is the server, the internet route, your Wi-Fi, or your device — with a practical step-by-step fix guide.
A more organized way to watch your IPTV.
Download for iOS