This Python script allows you to download YouTube live streams in the best available quality (e.g., 1080p60) by dynamically selecting the formats and merging video and audio streams using ffmpeg
. The script includes an interactive interface for entering the YouTube URL, selecting the cookies file, and choosing the output directory.
- Downloads YouTube live streams from the start of the DVR buffer.
- Supports 1080p60 quality (if available).
- Merges video and audio streams into a single file.
- Interactive pop-ups for input.
- Python 3.7+ installed. You can download it from python.org.
- yt-dlp: Install using pip (
pip install yt-dlp
). - ffmpeg: Required for merging video and audio. Download ffmpeg and ensure it is added to your system's PATH.
- A cookies.txt file exported from your browser with authentication for YouTube.
- Clone this repository:
git clone https://github.com/Monster-ZeroX/YouTube-Live-Capture.git cd YouTube-Live-Capture
- Install the dependencies:
pip3 install -r requirements.txt
- Run the script:
python3 interactive_live_download.py
- Follow the pop-ups to:
- Enter the YouTube live stream URL.
- Select the cookies.txt file exported from your browser.
- Choose the output folder to save the downloaded video.
yt-dlp
: For downloading video and audio.ffmpeg
: For merging video and audio streams.
- If the script fails to run, ensure yt-dlp and ffmpeg are properly installed and accessible in your PATH.
- Check the cookies.txt file to ensure it includes valid YouTube authentication details.
This project is licensed under the MIT License. See the LICENSE
file for details.
Feel free to open an issue or submit a pull request for improvements and fixes.