How to Create Your Own IPTV Playlist (M3U) From Legal Sources
Learn how to create an M3U playlist for IPTV by hand: the file format, tags for names, logos and groups, legal stream sources, editing tools and testing.
By Vikings IPTV Editorial TeamUpdated 7 min read

An M3U playlist looks technical until you open one. It is a plain text file: a line describing a channel, a line with its address, repeated. You can write one in Notepad in five minutes. Making your own is a good way to understand how IPTV works, to tidy up a list you already have, or to gather streams you are entitled to watch into one place.
This guide shows the format, the tags that control how channels appear, where legitimate streams come from, and how to edit and test a playlist.
How do you create an M3U playlist for IPTV?
To create an M3U playlist, open a text editor, type #EXTM3U on the first line, then add two lines for each channel: an #EXTINF line with the channel's name and details, followed by the stream's web address. Save the file with the .m3u extension in UTF-8 encoding and open it in an IPTV player.
The format, line by line
Here is a complete two-channel playlist.
#EXTM3U
#EXTINF:-1 tvg-id="news.example" tvg-logo="https://example.com/news.png" group-title="News",Example News
https://example.com/live/news/playlist.m3u8
#EXTINF:-1 tvg-id="weather.example" group-title="Local",Example Weather
https://example.com/live/weather/playlist.m3u8| Part | Meaning |
|---|---|
#EXTM3U | Marks the file as an extended M3U playlist. Must be the first line. |
#EXTINF:-1 | Starts a channel entry. -1 means a live stream with no fixed length. |
tvg-id="..." | The ID used to match the channel to programme guide data |
tvg-logo="..." | Address of a logo image |
group-title="..." | The group or category the channel appears under |
,Example News | The display name, after the comma |
| The next line | The stream address |
Only the name and the address are essential. The tags make the list pleasant to use.
Step by step
- Open a plain text editor. Notepad on Windows, TextEdit on Mac (choose Format > Make Plain Text), or any code editor. Not a word processor.
- Type
#EXTM3Uon the first line. - Add each channel as an
#EXTINFline followed by its address. - Use consistent group names. "News" and "news" are two different groups.
- Save as
playlist.m3uwith UTF-8 encoding. On Windows, set the file type to "All files" so it does not becomeplaylist.m3u.txt. - Test it in VLC before loading it on a TV.
The background on the file type itself is in what is an M3U file?
Where legal streams come from
A playlist is only a list of addresses. What matters is whether you are entitled to the streams it points to.
| Source | Notes |
|---|---|
| Your own IPTV subscription | Your provider's playlist is yours to rearrange for personal use |
| A home TV tuner | Network tuners that receive antenna channels publish a playlist for your own network |
| Your own cameras and media server | Streams you produce yourself |
| Public streams from broadcasters | Some public, government and community broadcasters publish stream addresses for general use; check their terms |
| Public-domain and openly licensed channels | Published by their owners for free use |
Three things to avoid:
- Copying stream addresses out of a broadcaster's website or app when its terms do not permit it. Being able to find an address does not make it yours to use.
- "Free IPTV" playlists from forums and file-sharing sites. They are almost always unlicensed, they break constantly, and the sites hosting them are a common source of malware.
- Sharing your subscription's playlist. It contains your login. Anyone with the file can use your connections, and sharing normally breaches the provider's terms.
IPTV technology is legal; a stream needs the rights holder's permission. See our overview of IPTV legality.
Editing a playlist you already have
The most common reason to work on a playlist is to tidy one from your provider: thousands of channels reduced to the fifty you watch.
- Download the playlist using your M3U link in a browser, and save the file.
- Open it in a text editor.
- Delete the entries you do not want. Each entry is two lines; remove both.
- Rename groups by changing
group-title. - Reorder by moving pairs of lines.
- Save and load the file into your player.
One limitation: a saved file is a snapshot. When your provider changes a stream address, your copy will not update. For that reason, most people are better off tidying inside the player instead, by hiding groups and building favourites. See how to organize your TiviMate channel list.
M3U editors
For large playlists a dedicated editor is easier than a text editor. An M3U playlist editor shows channels in a table, where you can sort, filter, rename, regroup and delete in bulk.
They come in three kinds.
| Type | Good for | Caution |
|---|---|---|
| Desktop editors | Working offline on a saved file | None in particular |
| Any spreadsheet or code editor | Bulk find-and-replace | Easy to break the two-line structure |
| Online editors | Convenience, hosted output links | Your playlist, including your login, is uploaded to a third party |
If you use an online editor, remember that you are handing your credentials to another company. Read its privacy terms, or use an offline tool.
Adding a programme guide
A playlist has no programme information. That comes from a separate XMLTV file, matched to channels through tvg-id.
- If your streams come from a provider, use the guide link it supplies and keep the
tvg-idvalues unchanged. - For a tuner, the tuner's software usually provides guide data.
- A guide link can be included in the first line:
#EXTM3U url-tvg="https://example.com/guide.xml".
How matching works is explained in EPG sources for IPTV.
Testing your playlist
- Open VLC.
- Choose Media > Open File and select the playlist, or drag the file onto VLC.
- Open the playlist view and try each channel.
If a channel fails in VLC, it will fail everywhere. See how to watch IPTV on VLC.
Common mistakes
| Problem | Cause | Fix |
|---|---|---|
| Player says the file is invalid | First line is not #EXTM3U | Add it |
| Nothing loads | Saved as .m3u.txt or as a rich-text document | Save as plain text with the right extension |
| Accented names look wrong | Not saved as UTF-8 | Re-save with UTF-8 encoding |
| A channel shows but will not play | Address mistyped or stream offline | Test the address alone in VLC |
| Channels in the wrong group | Inconsistent group-title spelling | Standardise the names |
| No guide data | Missing or mismatched tvg-id | Match the IDs to the guide source |
| Two channels merged | A missing line break | Check each entry is exactly two lines |
Using the playlist on your devices
- Computer: open the file directly.
- TV players: most want a web address rather than a file. Some can read a file from USB storage or a home network share.
- Hosting: if you put a playlist online so a TV can reach it, keep the link private. Anyone with it can use what is inside.
How to load a link in each major app is covered in how to use an M3U link for IPTV.
Frequently asked questions
Can I make my own IPTV playlist?
Yes. An M3U playlist is a plain text file listing channel names and stream addresses, which you can write in any text editor.
Is creating an M3U playlist legal?
Creating the file is legal. What matters is the streams in it: you need to be entitled to watch them, for example through your own subscription, tuner or streams published for public use.
What program do I need to make an M3U file?
Any plain text editor, such as Notepad or TextEdit. Dedicated M3U editors make large playlists easier to manage.
What is the difference between M3U and M3U8?
M3U8 is an M3U file saved in UTF-8 encoding. For IPTV playlists the two are used interchangeably.
Why will my M3U playlist not load?
Usually because the first line is missing, the file was saved with the wrong extension or as rich text, or an address is mistyped.
Summary
To create an M3U playlist, start with #EXTM3U, add an #EXTINF line and an address for each channel, and save as plain UTF-8 text. Use tags for logos, groups and guide matching, fill it only with streams you are entitled to, and test in VLC.
Our plans include an M3U link and guide data you can organise to suit yourself.



