> For the complete documentation index, see [llms.txt](https://ghost-cable.gitbook.io/ghost-cable-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ghost-cable.gitbook.io/ghost-cable-docs/chapter-3-connection-methods-how-to-login/xtream-codes-api-setup-guide.md).

# Xtream Codes API Setup Guide

When logging into an IPTV app, you will usually be given a choice between using a long M3U playlist URL or the Xtream Codes API.

We highly recommend using the Xtream Codes API route. Instead of forcing you to type out a massive, complex web link containing hundreds of characters, Xtream Codes breaks your subscription line down into three simple, human-readable pieces of information.

### 🌟 Why Xtream Codes is the Best Option

* Fewer Typos: It splits your login credentials into clean, manageable boxes (Server, User, Pass).
* Automated Updates: It maps out an intelligent cloud connection to our database. If we add new channels, fix broken movie files, or update the TV Guide (EPG), your app updates itself automatically every time you launch it.
* Separated Data Tracks: It tells your app exactly where to look for live channels versus movie posters, leading to a drastically faster loading speed on streaming sticks.

### 📸 Visual Layout Example

When you select "Login with Xtream Codes API" or "XUI / XC Login" inside your preferred IPTV player (like TiviMate, IPTV Smarters, or XCIPTV), you will see a text field layout that looks exactly like this:

```
┌─────────────────────────────────────────────────────────────┐
│                       ANY NAME                              │
│  [ Home IPTV (or any nickname you want)                 ]   │
├─────────────────────────────────────────────────────────────┤
│                     SERVER URL / HOST                       │
│  [ http://example-domain.com:8080                       ]   │
├─────────────────────────────────────────────────────────────┤
│                       USERNAME                              │
│  [ your_unique_username_here                            ]   │
├─────────────────────────────────────────────────────────────┤
│                       PASSWORD                              │
│  [ your_secure_password_here                            ]   │
└─────────────────────────────────────────────────────────────┘
                [   LOGIN / CONNECT   ]
```

### 🛠️ Step-by-Step Configuration

To map your subscription successfully, fill out the interface boxes using the exact parameters sent to you in your activation message:

**1.Give It a Name:**&#x53;tep 1.

Click into the top Any Name or Playlist Name box. This is completely for your own reference. Type in anything you'd like, such as "My TV" or "Main Server".

**2.Input the Server URL / Host:**&#x53;tep 2.

Enter the Server URL (sometimes called the *Host* or *Portal link*). This link tells your app exactly which data center to fetch streams from. It always starts with `http://` and almost always ends with a specific numerical port code, such as `:8080`, `:2086`, or `:826`.

**3.Enter Your Username:**&#x53;tep 3.

Type your account Username into the third row. Remember that this is completely case-sensitive and must not contain any blank spaces at the beginning or end.

**4.Enter Your Password:**&#x53;tep 4.

Type your account Password into the fourth row. Double-check your spelling to ensure your device's virtual keyboard didn't automatically change any letters or numbers.

> 🚀 Launch the System: Once all three core lines match your activation credentials letter-for-letter, highlight and click the Login, Add User, or Connect button at the bottom of your screen. The player app will run a secure handshake with our backend panel and instantly populate your TV screen with channels!
