▲ 17 r/Chromecast
A tool to stream local video files to Chromecast with on-the-fly transcoding (castlocal)
I wrote a small web tool called castlocal to play local video files from a PC on a Chromecast without setting up a media server.
What it does:
- Playback: Scans local directories (
~/Downloadsand~/Videosby default). You open the web interface from your PC or phone, choose a video, choose the Chromecast, and hit play. - Transcoding: Direct plays MP4 (H264 + AAC). Transcodes MKV, HEVC, AVI, and unsupported audio like DTS on the fly using
ffmpeg. Seeking recalculates the conversion from the selected timestamp so sync isn't lost. - Subtitles: Automatically loads local
.srtor.vttfiles with matching names. It also lets you upload a file manually, search OpenSubtitles from the UI, or nudge the timing by±0.5s. - Controls: Play, pause, seek, and volume work natively through the Google Home notification on Android/iOS.
- Linux integration: Includes a desktop toggle script (starts/stops the server on double-click) and a
systemd --userservice.
Stack & Requirements:
- Python 3.11+ (uses
uv) ffmpegwithlibx264- Built with Flask and
pychromecast. Tested on a 1st-gen Chromecast.
u/redbone3005 — 1 month ago