rtp2httpd is a free, open source media & streaming project written in C and released under GPL-2.0. It has 2,080 GitHub stars, 322 forks and 29 open issues, and was last pushed 13 hours ago. On this registry it ranks #17 of 27 tracked projects in Media & Streaming, with 5 head-to-head comparisons available. It gained 25 stars over the last 3 tracked days.

What is rtp2httpd?

What it is

rtp2httpd is a C-based IPTV streaming forwarder that converts multicast RTP/UDP and RTSP sources into unicast HTTP streams for clients that cannot join multicast directly. It lives in the IPTV media-streaming ecosystem, with topics including china-iptv, iptv, iptv-m3u, iptv-player, msd-lite, multicast, rtp, rtp-proxy, rtsp-proxy, and udpxy.

The project addresses the fact that many IPTV services deliver television as multicast RTP or RTSP, which ordinary browsers, mobile clients, and LAN media clients often cannot consume. It converts those feeds into HTTP, proxies internal HLS sources outward, normalizes M3U playlists, and supports fast channel change so users can watch IPTV on common devices without relying only on operator set-top boxes.

Key capabilities

  • It converts multicast RTP/UDP to HTTP and RTSP to HTTP, with UDP NAT traversal STUN and RTSP time-shift playback.
  • It provides full reverse proxy for HTTP-to-HTTP streaming, allowing internal IPTV HLS sources to be served to LAN or public network clients.
  • It integrates M3U and M3U8 playlists, converts RTP or RTSP addresses into HTTP proxy format, handles catchup-source time-shift addresses, and exposes a converted playlist at /playlist.m3u.
  • It reduces packet loss and jitter by reordering out-of-sequence RTP packets and supporting Reed-Solomon FEC recovery when the multicast upstream provides FEC.
  • It supports carrier FCC fast channel change, delivers IDR frames for immediate decoding, and provides HTTP channel snapshots to reduce client-side decoding load.
  • It offers a web status page at /status that shows client IP, state, bandwidth, transferred data, logs, dynamic log levels, and forced client disconnect.
  • It includes a built-in browser player at /player with adaptive desktop and mobile UI, EPG, time-shift, automatic deinterlacing, and AMD FSR 1 upscaling.

Who uses it and how

  • IPTV users on OpenWrt routers, optical modems, NAS, or other embedded devices convert multicast TV feeds into HTTP streams for local clients.
  • Operators proxy private IPTV HLS sources to home networks or public clients using the HTTP-to-HTTP reverse proxy mode.
  • Clients consume generated M3U or M3U8 playlists through udpxy-compatible URLs, enabling players that expect standard HTTP streaming.
  • Advanced IPTV setups pair the server with carrier FCC servers and optimized players such as mytv-android, TiviMate, or Cloud Stream for faster channel switching.

Getting started

Typical deployment follows the OpenWrt quick-start guide or the platform-specific installation documentation, with related tutorials for DHCP authentication, routing, multicast, and firewall setup.

When to use it — and when not to

Use it when you need a lightweight C forwarder for multicast IPTV, RTSP sources, and HTTP proxying on embedded or self-managed hardware. Do not choose it for a fully hosted IPTV platform or when you cannot manage multicast routing, carrier FCC servers, RTSP catch-up sources, or FEC-capable upstream streams. The built-in browser player also inherits browser decoding limits, so some channels may fail to show video or audio.

project readme (upstream, from github) — read inline

rtp2httpd - IPTV 流媒体转发服务器

[>> 访问官方文档网站 > English Documentation HTTP**:将组播 RTP/UDP 流转换为标准 HTTP 流

  • RTSP->HTTP:RTSP 转为 HTTP 视频流,完整支持 RTSP/RTP 协议栈,支持 UDP NAT 穿透 (STUN)
    • 可以实现 IPTV RTSP 时移源的回看
  • HTTP->HTTP:实现了完整反向代理,可以将 IPTV 内网 HLS 源代理到局域网、公网,方便观看
  • udpxy 兼容性:完全兼容 udpxy URL 格式
  • M3U 播放列表集成:支持 M3U/M3U8 格式,自动识别并转换节目地址,提供标准化的播放列表
    • 支持外部 M3U URL
    • 智能识别 RTP/RTSP URL 并转换为 HTTP 代理格式
    • 自动处理 catchup-source 时移回看地址
    • 通过 http:///playlist.m3u 访问转换后的播放列表
  • 抗丢包抗抖动:支持乱序恢复、FEC 前向纠错技术,保证播放质量
    • 自动纠正乱序到达的 RTP 包,消除网络抖动导致的花屏
    • 支持 Reed-Solomon FEC 冗余恢复,可抵抗轻度丢包(需组播上游支持 FEC)
  • 频道快照:支持通过 HTTP 请求快速获取频道的快照图片,降低播放端解码压力

⚡ FCC 快速换台技术

  • 支持运营商 FCC 协议:搭配运营商 FCC 服务器,实现毫秒级换台响应,媲美原生 IPTV 机顶盒
  • 快速解码:FCC 保证了换台时迅速提供 IDR 帧,可供播放器立即解码

📊 实时状态监控

  • Web 状态页面:通过浏览器访问 http:///status 查看实时运行状态
  • 客户端连接统计:显示每个连接的 IP、状态、带宽使用、传输数据量
  • 系统日志查看:实时查看服务器日志,支持动态调整日志级别
  • 远程管理功能:通过 Web 界面强制断开客户端连接

🎬 内置播放器

  • 浏览器直接使用:内置基于 Web 的现代化播放器界面,可以在浏览器直接打开播放,桌面/移动端 UI 自适应
  • 快速起播:搭配 FCC 可实现快速起播、快速换台
  • 支持时移和回看:支持 EPG 电子节目单,支持时移和回看(需要有 RTSP 回看源)
  • 零开销:纯 Web 前端实现,对 rtp2httpd 运行几乎没有资源占用(无解码转码开销)
  • 画质增强:支持自动反交错、AMD FSR 1 超分辨率技术,优化 576i / 1080i 在现代 2K/4K 屏幕上的表现

🚀 高性能优化

  • 非阻塞 IO 模型:使用 epoll 事件驱动,高效处理大量并发连接
  • 多核优化:支持多 worker 进程,充分利用多核 CPU 提高最大吞吐量
  • 缓冲池优化:预分配缓冲池,避免频繁内存分配,多客户端根据负载动态共享,避免慢客户端吃满资源
  • 同源复用:同一工作进程内共享组播订阅、RTP 处理和批量缓冲,减少多客户端重复工作
  • 轻量化:使用纯 C 语言编写,零依赖,小巧简洁,适合运行在各种嵌入式设备上(路由器、光猫、NAS 等)
    • 程序大小仅 509KB (x86_64),并内置了 Web 播放器所有前端资源
  • 查看 性能测试报告(与 msd_lite、udpxy、tvgate 的性能对比)

📹 演示效果

快速换台 + 时移回看

https://github.com/user-attachments/assets/ca1a332f-d6e7-4a1e-be88-92bef67758b3

[!TIP] 快速换台需要使用针对 IPTV 优化的播放器,例如 mytv-android / TiviMate / Cloud Stream 等(视频中的播放器是 mytv-android)。 常见普通播放器,例如 PotPlayer / IINA 等,没有专门优化起播速度,FCC 效果不明显。

内置播放器

https://github.com/user-attachments/assets/d3dab0c0-03c4-453b-86ae-85406e5208eb

[!TIP] 需要配置 M3U 播放列表后使用,通过浏览器访问 http:///player 即可打开。 受限于浏览器解码能力,一些频道可能不支持(表现为无音频、画面黑屏)。

实时状态监控

web-dashboard

25 条 1080p 组播流同时播放

https://github.com/user-attachments/assets/9d531ab6-6c35-4c50-802a-71f88b6b22c5

[!NOTE] 单流码率 8 Mbps。总仅占用 25% CPU 单核 (i3-N305),消耗 4MB 内存。

📖 文档

如果是首次搭建 IPTV 组播转发服务,对相关网络知识比较陌生(DHCP 鉴权、路由、组播、防火墙),推荐先看 搭建教程

📄 开源许可

本项目基于 GNU General Public License v2.0 开源协议发布。这意味着:

  • ✅ 可以部署在商业环境中(如企业内部使用)
  • ✅ 可以基于它提供收费的 IPTV 转码服务
  • ✅ 可以在有偿 IPTV 咨询服务中使用本软件
  • ✅ 可以销售包含此软件的硬件设备
  • ⚠️ 如果修改代码,必须公开修改后的源代码
  • ⚠️ 如果分发二进制文件,必须同时提供源代码
  • ⚠️ 不能将其闭源后再销售

🙏 致谢

  • 原始项目 oskar456/rtp2httpd 的开发者们
  • 愿意在互联网上公开 FCC 协议细节的业内人士
  • 所有测试和反馈用户

Frequently asked questions

Is rtp2httpd free to use?

rtp2httpd is open source under the GPL-2.0 licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does rtp2httpd do?

Multicast RTP/RTSP to Unicast HTTP stream converter, with built-in web player, status dashboard, fast channel change support, and more!

What is rtp2httpd written in?

rtp2httpd is primarily written in C. Its source is publicly available at https://github.com/stackia/rtp2httpd, and it has 2,080 GitHub stars.