Skip to main content

Streaming IPTV on Plex using xTeVe and EPG.Best!

Publication date: 2021-12-20

Introduction

This guide will cover getting IPTV working on Plex, using xTeVe and EPG.Best

The end result of this guide is watching IPTV streams in Plex. My example with 3 channels:
Screenshot

I am able to watch the IPTV streams on my computer (in a browser on Windows), on my TV (Plex app on an LG tv) and on my mobile (Plex app on an LG android phone).

Writing a guide like this takes time and effort; tips are appreciated.
My crypto addresses can be found here.



Contents



1 Requirements

The following is required:

  • Plex Pass subcription,
  • An IPTV subcription (.m3u or Xtream).
  • EPG.Best, that will provide EPG data.
  • xTeVe, software that allows to watch IPTV on Plex.

1.1 Plex Pass subscription

To watch live tv streams, you need the 'Live TV & DVR' functionality in Plex. This functionality is not free, and is part of the Plex Pass subscription.

So, you need to have a Plex Pass subscription.
Get a Plex Pass if you don't have one yet. More info here: https://www.plex.tv/plex-pass/.


1.2 An IPTV subcription

You need to have an IPTV subscription from, to get access to the live tv streams. There are legal and illegal providers that provide the access. I would recommend checking the laws and regulations in your country to see what is/isn't allowed.

IPTV providers can send you a link of the .m3u file, or Xtream login details. Both work fine.

To make this guide, I have bought a random IPTV subscription that was valid for 24 hours, on https://aliexpress.com/.


1.3 EPG.Best

EPG.Best is an online .m3u editor and playlist manager. It also provides the Electronic Program Guide (EPG) data that is required by xTeVe.

It's a paid service.

I would appreciate it if you register with my referral link: https://epg.best/register?referrer=107278.


1.4 xTeVe

xTeVe is the proxy software that allows you to watch IPTV on Plex. It's like the bridge between the IPTV streams and Plex. It's free.

The GitHub repository: https://github.com/xteve-project/xTeVe.



2 Import channels in EPG.Best and get EPG

IPTV providers often give access to hundreds of channels. If you're like me, you're mostly interested in a small number of channels. By ignoring/removing the channels that you're not interested in, the load times in xTeve and Plex will sped up later on.

EPG.Best has an online editor, that will allow select the channels that you're interested in. After selecting the channels, the service will provide an Electronic Program Guide (EPG) file.

  • Your IPTV provider will provide you with a link to the .m3u file. You can either use that link, or download the .m3u file to your computer.
    Screenshot

  • After registering an account, login on EPB.Best: https://epg.best/login.

  • The 'Add a new M3U file' screen will appear.
    You can either copy/paste the link of your .m3u file, upload the .m3u file from your computer, or use your Xtream login details. I have chosen to copy/paste the link. Click on 'Continue' to... continue.
    Screenshot

  • The .m3u file will be processed. Wait patiently until the process finishes.
    Screenshot

  • After the .m3u file is processed, you will se a list of your 'channel groups'.
    Screenshot

    • For the groups that you are interested in and want to keep, select the action 'Get EPG'.

    • For all others, select 'No import, delete from M3U'.

    • Some channel groups have no 'Get EPG' option, only 'keep' or 'delete'. As you're only interested in channels with EPG (visible in Plex later), for these channel groups, I select 'Delete from M3U'.

  • For the purpose of this guide, I am only interested in a few tv channels in the US. So, I make sure all the channel groups have either 'Delete from M3U' or 'No import, delete from M3U' selected.

    And then, I select the one I am interested in. In my case, that's USA General. I select 'Get EPG' as action, and click on 'Save'.
    Screenshot

  • In the next screen, you will pair channels, by matching the channels with the EPG data. The channel list that you see are the channels from the channel group you selected in the previous screen.
    Screenshot

    In some cases, the channels and EPG is matched automatically. Check if the matches are correct. If you're interested in the channel, make sure 'Get EPG' is selected as action. If not interested, select 'No EPG, keep in M3U' - this will keep the channel in the editor the next time you edit your channels. If you want do not want to see the channel again next time, you can select 'Delete from M3U and editor' to delete the channel completely.
    Screenshot

    If you want to change multiple channels at the same time:

    • Set the 'Per page' setting to 100 (too see more channels on one page).
      • Use the checkbox on the left side to select channels (or use the checkbox at the top to select all channels at once).
      • Click on 'Edit selected channels' on the upper right corner.

  • Start matching the channels that you are interested in. You do this by selecting the correct TVG-ID in the 'Select the matching TVG-ID' column.

    In case of US channels, a lot of the channels have a TVG-ID that ends on .us.

    Let's say that I am interested in three random US tv channels: Cartoon Network, Comedy Central and MTV.

    I search for these three channels in the channel list, and enter the correct TVG-ID.

    I make sure that the channels that I am interested in, have 'Get EPG' as action. And the others are all 'No EPG, keep in M3U'.

    If you want, you can order the channels by adjusting the 'Ch. No.' column.

    Click on 'Save and continue' at the bottom to continue.

  • A new .m3u file is being created. This file will only contain the channels that you have selected.
    Screenshot

  • After your .m3u is generated, you will be send back to your 'My channels' page. You will now see your personal EPG XML link, and your personal .m3u link.
    Screenshot

    You will need these two links later.



3 Set up xTeve

3.1 Initial configuration

  • Download xTeVe from its GitHub repository:
    https://github.com/xteve-project/xTeVe#downloads-v2--64-bit-only.

  • Download the .zip file for your operating system, and extract the contents. I'm on Windows, so I have downloaded the Windows file, and extracted the files into C:\xteve\. You can use any folder that you want.
    Screenshot

  • Run the xTeVe program. It will show you its settings, including the 'Web Interface' address.
    Screenshot

    Open this address in your browser. You will be greeted by the Configuration screen of xTeVe.
    Screenshot

  • 'Number of tuners' is how many parallel/concurrent streams you're allowed to have by your IPTV provider. If you're not sure, go with 1, and click on 'Next'.

  • As EPG Source, use 'XEPG'.
    Screenshot

  • You will be asked for the .m3u file. Copy the link from EPG.Best, paste it here, and click on 'Next'.
    Screenshot

  • As the 'XMLTV File', enter the EPG XML link from EPG.Best, and click 'Next'.
    Screenshot

  • Configuring xTeVe is completed, the Web Interface is loaded.
    Screenshot

3.2 xTeVe mappings

The next step is to check the mappings.
The mappings will show how the .m3u and EPG file have been interpreted by xTeVe.
You can also deactive a channel if you're not interested in it.

  • In the xTeVe Web Interface, click on 'Mappings' on the left menu to open the Mappings page.

  • On the left side of the table, every channel will have a color. Green is 'active', red is 'not active'. Channels that you want to see later in IPTV should be green.

    In my case, I see the three channels that I am interested in, and all are green.
    This means that these channels should be visible in Plex later.
    Screenshot

  • If a channel is red and thus 'not active', you can check its settings by clicking on the channel and changing the settings.

After the mappings are as desired, you can continue to the "4. Configure Plex" chapter below.
However, I would recommend reading chapter "3.4 FFMPEG (optional)" below.


3.3 FFMPEG (optional)

If your streams are laggy and have some kind of stutter, you can adjust your 'stream buffer' settings in xTeVe to get beter results.
xTeVe allows three different buffering solutions; this guide will use the 'FFMPEG' method.

FFMPEG is a set of tools for handling video and audio files and streams. You can read more about it on Wikipedia.

  • Download FFMPEG. The available packages for Linux, macOS and Windows are available on https://www.ffmpeg.org/download.html.

    I am using Windows, and I am using the 'windows builds from gyan.dev'.
    I have downloaded: release builds → ffmpeg-release-full.7z, from https://www.gyan.dev/ffmpeg/builds/#release-builds.
    Screenshot

  • The contents of the file need to be extracted. It's a .7z file, you can use 7-Zip to extract the contents.

  • You can download 7-Zip from its website, but I prefer the portable version (much cleaner, keeps everything in 1 folder). You can download the portable version from Portable Apps.

  • After downloading, installing and running 7-Zip, you can extract the ffmpeg-release-full.7z file.

  • You can run 7-Zip, browse to the location where the ffmpeg-release-full.7z file is located, select the file and click on 'Extract'.
    Screenshot

    Or you can open the file directly in 7-Zip via the Windows File Explorer: right click on the ffmpeg-release-full.7z → Open with → Choose another app → More apps → Look for another app on this PC. Browse to the location where 7-Zip Portable is installed, and select '7-ZipPortable.exe'.

  • I have extracted the contents of the .7z file into C:\xteve\ to keep it everything together.
    Screenshot

    To make life easier, I have renamed the extracted folder to ffmpeg.
    Screenshot

    The file xTeve needs, is ffmpeg.exe in the 'bin' folder.

  • Now, go to the xTeve Web Interface, and select 'Settings' in the left menu.
    Scroll down until you see the settings for 'Streaming'.
    Screenshot

  • Apply these settings:
    • Stream Buffer: 'FFMPEG: (FFMPEG connects to the streaming server)'.
    • Buffer Size: '4 MB'.
    • FFmpeg Binary Path: C:\xteve\ffmpeg\bin\ffmpeg.exe (adjust to your own location).

  • Click on 'Save' to save these settings.

It might be that a different buffer size is more optimal for you. So, if '4 MB' does not work for you, try lower.

Everything in xTeve is now configured.
You can continue to chapter "4. Configure Plex".



4 Configure Plex

  • Make sure xTeve is running!

  • Open Plex, and go to your Settings.

  • In Settings, in the left menu under 'Manage', click on 'Live TV & DVR'.
    Screenshot

  • In the 'Live TV & DVR' page, click on 'SET UP PLEX DVR' to continue.
    Screenshot

  • xTeVe might be detected automatically.
    If not, click on 'Don't see your HDHomeRun device? Enter its network address manually'.
    Enter the 'DVR IP' that you see in the xTeVE Web Interface.
    Screenshot

    After clicking on 'Connect', you should see a tuner appear.
    Screenshot

    Scroll down, and click on 'Have an XMLTV guide on your server? Click here to use it'.

  • In the 'Use an XMLTV guide' screen, enter/select these values:

    • Language: English (or what applies in your case).
    • XMLTV Guide: your EPG XML file link from EPG.Best.
    • Guide Title: you can give it a title, or leave the default 'My Guide'.

    For me, it looks like this:
    Screenshot

    Click on 'Continue'.

  • Your channels will be shown.
    Screenshot

    Make sure to link every tuner channel to its EPG channel.
    Enable the channel first by clicking on the checkbox on the left.
    Screenshot

    After all channels have been linked, click on 'Continue'.

  • The settings will be applied. When all is finished, click on 'View Guide' to see your channel list.
    Screenshot

This is the end result:
Screenshot

Click on the number on the left of the channels to start watching the selected channel!

Streaming Cartoon Network via Plex:
Screenshot

As a bonus, you can also record a stream by clicking on the record button!
Screenshot