🎉 A lightweight YouTube to IPTV streaming server built with Hono, Bun, Nunjucks, and TailwindCSS (DaisyUI).
📺 Transform your non-smart TV into a YouTube streaming device via IPTV!
This project is designed to generate an M3U file for IPTV players, allowing you to stream YouTube videos directly to a TV via your home network. It includes a web interface where users can search for and select YouTube videos, dynamically creating IPTV streams for them.
Many older TVs do not have access to modern streaming services like YouTube. yt-iptv-hono offers a workaround by leveraging IPTV streams, allowing these older devices to play YouTube content over a shared home network.
- YouTube to IPTV: Generate M3U files that IPTV players can use to stream YouTube videos.
- Web Interface: Built using Nunjucks, DaisyUI, and TailwindCSS for a clean, responsive UI.
- Search and Play: Search for YouTube videos directly from the web interface and add them to the playlist.
- Supports Legacy TVs: Stream YouTube videos to non-smart TVs over a shared Wi-Fi network.
- Dynamic Playlist: The M3U file dynamically updates the YouTube video being played.
- Ensure your TV and the device running this server are on the same Wi-Fi network.
- You'll need to regenerate and re-download the M3U file if the device's IP address changes.
-
Clone the repository:
git clone https://github.com/nachat-ayoub/yt-iptv-hono.git cd yt-iptv-hono -
Install dependencies:
bun install
-
Start the server:
bun run src/index.ts
-
Access the web interface at
http://localhost:3000to search and select YouTube videos.
- After starting the server, download the M3U file from the web interface. This file can be used by your TV's IPTV player to stream YouTube videos.
- If the device's IP address changes, you'll need to regenerate and re-download the M3U file.
- Same Wi-Fi Network: The TV and server device must be connected to the same Wi-Fi network (unless deployed).
- Dynamic IP: If the server's device IP changes (common on home networks), you'll need to download and update the M3U file again.
- YouTube Video Playback: Limited to the capabilities of the IPTV player on your TV.
If you wish to remove the limitation of requiring the same Wi-Fi network, you can deploy this app. However, YouTube's restrictions may prevent direct video streaming when deployed. Visit the @distube/ytdl-core GitHub repository to explore how to handle these limitations.
This project is licensed under the MIT License. See the LICENSE file for details.
