M3UExamples

M3U File Examples — Copy-Paste Playlist Templates for Every Use

Looking for M3U examples you can copy and customize? This comprehensive collection of M3U examples covers every common use case. From basic local music M3U examples to complete IPTV live TV M3U examples with EPG support, each M3U example includes clear explanations. These ready-to-use M3U examples help you create playlists quickly — just copy the M3U example that fits your needs, replace the example URLs with your own content, and validate before loading into your player.

Updated June 2025·5 min read
M3U File Examples - Ready-to-use playlist templates

How to Use These M3U Examples

Each M3U example on this page is production-ready — you can copy the code directly, replace the example URLs with your actual content, save as a .m3u file, and load into any compatible player. Here's the workflow for adapting any M3U example to your needs:

1. Copy M3U Example

Select and copy the M3U example code that matches your use case — local files, internet radio, IPTV live TV, or VOD.

2. Replace URLs

Change http://provider.example.com/... to your actual stream URLs or file paths. Update channel names and metadata.

3. Validate & Test

Paste into the M3U Validator to check for errors, then load into VLC or your IPTV app to test playback.

Important: All URLs in these M3U examples are placeholders. They won't work until you replace them with valid stream URLs from your IPTV provider, media server, or local file paths. The M3U examples show proper syntax and structure — you provide the actual content URLs.

Local music playlist — Basic M3U example

A basic M3U example pointing to MP3 files on your computer. This simple M3U example uses relative paths so you can move the folder anywhere.

example.m3uCopy and customise
#EXTM3U

#EXTINF:233,Nirvana - Come as You Are
Come as You Are.mp3

#EXTINF:294,Radiohead - Creep
Creep.mp3

#EXTINF:195,Oasis - Wonderwall
Wonderwall.mp3

Internet radio

Live audio streams with no fixed duration. Duration is -1 for all live content.

example.m3uCopy and customise
#EXTM3U

#EXTINF:-1,BBC Radio 1
http://stream.live.vc.bbcmedia.co.uk/bbc_radio_one

#EXTINF:-1,NPR News
https://npr-ice.streamguys1.com/live.mp3

#EXTINF:-1,Jazz FM
https://stream.jazzfm.com/jazzfm

IPTV live TV channels — Complete M3U example

Full IPTV M3U example with all recommended attributes — logo, EPG ID, group, and display name. This M3U example shows proper IPTV playlist structure.

example.m3uCopy and customise
#EXTM3U x-tvg-url="http://epg.example.com/xmltv.xml"

#EXTINF:-1 tvg-id="bbc.one.uk" tvg-name="BBC One" tvg-logo="https://logos.example.com/bbc1.png" group-title="UK",BBC One HD
http://provider.example.com/live/user/pass/101.ts

#EXTINF:-1 tvg-id="sky.sports.main" tvg-name="Sky Sports Main" tvg-logo="https://logos.example.com/skysports.png" group-title="Sports",Sky Sports Main Event
http://provider.example.com/live/user/pass/201.ts

#EXTINF:-1 tvg-id="cnn.us" tvg-name="CNN" tvg-logo="https://logos.example.com/cnn.png" group-title="News",CNN International
http://provider.example.com/live/user/pass/301.ts

VOD (Video on Demand)

Films and TV episodes with actual durations in seconds. No EPG needed — duration is the runtime.

example.m3uCopy and customise
#EXTM3U

#EXTINF:9180 tvg-logo="" group-title="Movies | Action",The Dark Knight (2008)
https://vod.example.com/movies/dark-knight.mp4

#EXTINF:8100 tvg-logo="" group-title="Movies | Sci-Fi",Interstellar (2014)
https://vod.example.com/movies/interstellar.mp4

#EXTINF:2520 tvg-logo="" group-title="TV | Drama",Breaking Bad S01E01
https://vod.example.com/tv/bb/s01e01.mp4

Mixed live + VOD playlist — Advanced M3U example

This advanced M3U example combines live channels and on-demand content in one file. Groups keep them separated in the player UI.

example.m3uCopy and customise
#EXTM3U x-tvg-url="http://epg.example.com/xmltv.xml"

#EXTINF:-1 tvg-id="bbc.one.uk" tvg-name="BBC One" tvg-logo="https://logos.example.com/bbc1.png" group-title="Live TV",BBC One HD
http://provider.example.com/live/user/pass/101.ts

#EXTINF:-1 tvg-id="cnn.us" tvg-name="CNN" tvg-logo="https://logos.example.com/cnn.png" group-title="Live TV",CNN International
http://provider.example.com/live/user/pass/201.ts

#EXTINF:9180 tvg-logo="" group-title="Movies",The Dark Knight (2008)
https://vod.example.com/movies/dark-knight.mp4

Minimal valid M3U (no metadata)

The absolute minimum required for a valid basic M3U file. Works in all players but shows no channel names or logos.

example.m3uCopy and customise
#EXTM3U

http://provider.example.com/live/user/pass/101.ts
http://provider.example.com/live/user/pass/201.ts
http://provider.example.com/live/user/pass/301.ts

Understanding M3U Example Syntax

Every M3U example follows the same basic structure, but different use cases require different attributes. Here's what each part of an M3U example means:

#EXTM3U — Header

Every M3U example must start with this header. It tells media players the file contains extended metadata. Without #EXTM3U as the first line, most players treat the file as a basic URL list and ignore all metadata. The optional x-tvg-url attribute points to an EPG (Electronic Program Guide) XML file for live TV channels.

#EXTINF — Entry Metadata

This line appears before each stream URL in an M3U example. Format: #EXTINF:duration,Display Name. Duration is in seconds for files, or -1 for live streams. Everything after the final comma becomes the channel/track name shown in your player. The M3U examples above show both minimal and attribute-rich #EXTINF lines.

IPTV Attributes in M3U Examples

IPTV-specific M3U examples include these optional attributes inside the #EXTINF line:

  • tvg-id — EPG identifier for programme guide matching
  • tvg-name — Internal channel name (fallback for EPG)
  • tvg-logo — URL to channel logo image
  • group-title — Category name for organizing channels

These attributes are optional in M3U examples but highly recommended for IPTV playlists. They improve the viewing experience by adding logos, channel grouping, and programme information.

Stream URL — The Actual Content

The line immediately after #EXTINF is the stream URL or file path. In these M3U examples, URLs starting with http:// or https:// point to internet streams, while relative paths like Song.mp3 reference local files. Absolute local paths look like C:\Music\Song.mp3 on Windows or /home/user/Music/Song.mp3 on Linux/Mac.

Pro tip: Use the M3U Format Guide for a complete specification of every possible attribute you can include in M3U examples. The EXTINF Explained guide breaks down the metadata line in detail with advanced examples.

Common Mistakes When Adapting M3U Examples

Users frequently encounter these errors when customizing M3U examples for their own content:

Forgetting #EXTM3U Header

If your M3U example doesn't start with #EXTM3U, players ignore metadata and only show URLs. Always include this as line 1.

Blank Line Between #EXTINF and URL

The URL must be the immediate next line after #EXTINF. No blank lines allowed. This breaks most M3U examples if not followed correctly.

Invalid Duration Format

Duration must be an integer. Use -1 for live streams, seconds for files (e.g., 235 for a 3:55 song), not 3:55 or timestamps.

Wrong Slash Direction in Local Paths

Windows uses backslashes C:\Music\song.mp3, Linux/Mac use forward slashes /home/user/song.mp3. Match your OS or use relative paths like ./music/song.mp3 which work everywhere.

Unescaped Special Characters

If your URLs contain & or other special characters, they may need URL encoding (& becomes %26). Test your edited M3U example in the validator to catch these issues.

Frequently Asked Questions About M3U Examples

Can I copy these M3U examples?

Yes, all M3U examples on this page are free to copy, modify, and use in any project. Replace the example URLs with your own streams or media files before deploying. These M3U examples are provided as templates to help you understand proper syntax and structure.

Do M3U examples work for IPTV?

Yes, the IPTV live TV and VOD M3U examples are specifically designed for IPTV use. Make sure to replace example URLs with real stream URLs from your IPTV provider. The M3U examples include all necessary attributes (tvg-id, tvg-logo, group-title) for full IPTV functionality including EPG support and channel organization.

How do I test an M3U example?

After customizing an M3U example: (1) Save the code to a file with .m3u extension. (2) Paste into the M3U Validator to check for syntax errors. (3) Load the .m3u file into VLC, TiviMate, IPTV Smarters, or any compatible player to test playback. If streams don't play, verify your URLs are valid and accessible.

What's the difference between relative and absolute paths in M3U examples?

Relative paths (./music/song.mp3 or just song.mp3) work when media files are in the same folder as the M3U file or a subfolder. Absolute paths specify the full location: C:\Music\song.mp3 on Windows or /home/user/Music/song.mp3 on Linux/Mac. Absolute paths work from anywhere but break if you move files. Relative paths are portable but require maintaining folder structure.

Can I mix live streams and VOD in one M3U example?

Yes! See the "Mixed live + VOD playlist" M3U example above. Use -1 duration for live streams and actual seconds for VOD files. Use group-title attributes to separate them into categories like "Live TV" and "Movies" so your player organizes them in different sections.

Which M3U example should I use for my IPTV service?

Use the "IPTV live TV channels" M3U example if you're providing live television. It includes all recommended attributes for professional IPTV services: EPG URL, channel logos, IDs, and grouping. If you offer both live TV and on-demand movies/shows, use the "Mixed live + VOD" M3U example. For a simple radio station list, the "Internet radio" M3U example is sufficient.

Validate your M3U example after editing

After customizing any M3U example, paste your playlist into the validator to catch errors before loading into a player.

Validate M3U

Learn more about M3U examples and format