What Is tvg-id? How IPTV Channels Match the EPG (2026)
tvg-id is a small tag inside an M3U playlist that tells your IPTV player which channel in the guide file each stream belongs to. Every channel line in the playlist can carry a tvg-id, and every channel in the XMLTV guide file has an id of its own. When the two values are identical, the guide fills in with programme names and times. When they differ — even by one capital letter — that channel shows a blank guide or a "No Information" label. This one matching rule explains the majority of broken TV guides.
This guide shows you exactly where tvg-id lives, how the match works on both sides, and how to fix it when the guide goes blank. If you first want the bigger picture of what a TV guide is and where it comes from, read our IPTV EPG explainer and come back.
Where tvg-id lives: inside the #EXTINF line
Open any IPTV playlist in a text editor and you will see a two-line pattern repeated for every channel: an #EXTINF line with the channel’s details, then the stream URL. The tvg-id sits in that first line, next to a few sibling tags:
#EXTINF:-1 tvg-id="channel1.example" tvg-name="Channel One" tvg-logo="https://cdn.example/logo1.png" group-title="News",Channel One http://stream.example/live/channel1.ts
Nothing about the stream itself changes if you edit these tags. They are labels for the player: the logo to show, the folder to file the channel under, and — the important one — the id used to look up guide data. The playlist format is a simple extension of the plain M3U format that music players have used for decades; everything after #EXTINF:-1 is IPTV convention rather than an official standard. Our M3U playlist guide breaks down the full file structure if you want it.
How the tvg-id match actually works
The guide data comes from a second file, separate from the playlist: an XMLTV file, usually loaded from an "EPG URL" you paste into the player. XMLTV is an XML format for TV listings, and it has its own channel list inside. Each channel is declared once with an id, then every programme entry points back at that id:
<channel id="channel1.example"> <display-name>Channel One</display-name> </channel> <programme start="20260818200000 +0000" channel="channel1.example"> <title>Evening News</title> </programme>
When your player loads the playlist and the EPG, it builds a simple lookup: for each channel in the M3U, find the XMLTV channel whose id equals the tvg-id. The comparison is exact and case-sensitive. channel1.example and Channel1.Example are two different ids as far as the player is concerned, and a stray space inside the quotes breaks the match just as thoroughly. There is no fuzzy matching, no "close enough."
I have watched a guide go from blank to fully populated by changing a single capital letter in one tvg-id. That is genuinely how strict the match is — and it is good news, because it means the fix is usually mechanical rather than mysterious.

tvg-id vs tvg-name and the other tvg tags
The tags look interchangeable at a glance, and mixing them up is a classic reason a "correct-looking" playlist still shows no guide. Here is what each one actually does:
| Tag | What it does | Does it affect the guide? |
|---|---|---|
tvg-id | Links the channel to an XMLTV channel id | Yes — this is the match key |
tvg-name | A clean channel name for the player to display | Only as a fallback in some players when tvg-id is empty |
tvg-logo | URL of the channel logo image | No |
group-title | The category folder the channel appears in | No |
tvg-chno | A preferred channel number | No |
The fallback behaviour of tvg-name deserves a warning: a few players will try to match the name against the XMLTV display-name when no id is set. It works just often enough to be confusing and fails just often enough to be useless. Treat tvg-id as the only real match key.
Why the guide is blank even though the tvg-id looks right
"Looks right" is the trap — the player does not read the id the way your eyes do. When a channel shows no guide data, it is almost always one of these:
- The ids differ by a character. Case, a dot, a hyphen, a trailing space inside the quotes. Copy both values into a text editor and compare them side by side instead of eyeballing them in the app.
- The tvg-id is empty. Plenty of auto-generated playlists ship
tvg-id=""on half their channels. No id, no lookup, no guide. - You loaded the wrong EPG file. Provider playlists expect the provider’s own EPG URL. If you pair a provider playlist with a third-party XMLTV feed, the id conventions rarely line up — the feed may use completely different naming for the same channels.
- The EPG file does not cover that channel. Guide files only contain the channels their source tracks. A match cannot exist for a channel that simply is not in the file.
- The guide is stale or never refreshed. If every channel went blank at once, the EPG download itself failed. That is a source problem, not a matching problem — check the URL loads in a browser before touching any ids.

How to find the correct tvg-id for a channel
The authoritative list of valid ids is the XMLTV file itself. Open your EPG URL in a browser (or download it and open it in a text editor — it can be a large file) and look at the <channel id="..."> declarations near the top, before the programme entries begin. Whatever appears there, character for character, is what your playlist’s tvg-id has to say.
Two practical shortcuts:
- Use the EPG your provider ships. The playlist and guide are generated from the same channel database, so the ids already agree. This is the single highest-percentage fix for a broken guide.
- Search the XMLTV file for the channel’s name. The
display-namesits right next to the id, so a text search for the name reveals the id you need in seconds.
Three ways to fix a mismatch
1. Edit the playlist. If you keep a local M3U file, correct the tvg-id in a text editor and reload the playlist. This is the clean, permanent fix — the guide follows the file wherever you use it. If your playlist is a hosted URL you cannot edit, download a copy, fix it, and load the local file instead (you lose the provider’s automatic channel updates, so weigh that trade-off).
2. Map the channel inside the player. Most serious players let you assign guide data manually without touching the file. In TiviMate, long-press the channel, open its settings, and pick the right EPG entry from the list. Several other players hide the same feature under "EPG source" or "assign EPG" in the channel options. Our TiviMate vs IPTV Smarters comparison covers how differently the two handle guide management. Manual maps live inside that app on that device, so you will redo them if you switch players.
3. Change the EPG source. If dozens of channels are mismatched, do not fix them one at a time — you are using the wrong guide file. Switch to the provider’s own EPG URL, or to an XMLTV feed built for your playlist, and the bulk of the guide should light up on the next refresh. Slow or failing EPG downloads can also be a network issue; our IPTV error codes and DNS guide covers that side.
Using Xtream Codes or a portal? You can mostly skip all this
tvg-id headaches are overwhelmingly an M3U plus separate XMLTV problem. If you log into your service with an Xtream Codes login (server URL, username, password), the app requests the channel list and the guide from the same server API, already matched to each other — there is no id for you to align. The same goes for MAC-based portal logins. It is one reason the guide "just works" in Xtream mode for the same service that shows blank entries in M3U mode.
That does not make Xtream immune to guide problems — a provider whose electronic programme guide database is thin or mistimed will be thin or mistimed in every login format. But mismatched ids specifically are an M3U-side problem, and switching login formats is a legitimate way around them.
Frequently asked questions
What does tvg-id do in an M3U playlist?
It links each stream to its guide data. The player reads the tvg-id from the channel’s #EXTINF line and looks for an XMLTV channel with the same id. When it finds one, programme titles and times appear for that channel; when it does not, the guide stays blank.
Is tvg-id case-sensitive?
Yes. The match is exact: channel1.example and Channel1.Example are different ids to the player, and stray spaces inside the quotes count too. When a match fails, compare the two values character by character.
What happens if tvg-id is empty?
The player has nothing to look up, so that channel shows no guide. Some players fall back to matching tvg-name against the XMLTV display name, but it is unreliable. Add the correct id to the playlist or map the channel manually in the player.
Where do I find the correct tvg-id values?
Inside the XMLTV file: open your EPG URL in a browser and read the channel id declarations near the top. If you use the EPG URL your provider supplies with the playlist, the ids are already aligned and you rarely need to look anything up.
Do I need to worry about tvg-id with Xtream Codes?
No. An Xtream Codes login delivers the channel list and guide from the same server database, matched server-side. Id mismatches are an M3U-plus-external-XMLTV issue, so switching to the Xtream login format usually sidesteps the problem entirely.





