A simple and efficient command-line toolkit for downloading YouTube content, including videos, playlists, audio, and subtitles.
This Python script provides a user-friendly, menu-driven interface to download various types of content from YouTube. It leverages the pytubefix library to interact with YouTube and handle the downloads. The script is designed to be straightforward, prompting the user for all necessary information, such as URLs and save locations.
- Menu-Driven Interface: Easy-to-use command-line menu to select download options.
- Single Video Download: Download a single YouTube video in the highest available resolution.
- Playlist Download: Download all videos from a YouTube playlist in one go.
- Audio Extraction: Download only the audio from a single video or an entire playlist.
- Subtitle Download: Fetch and save subtitles for a single video or an entire playlist in your chosen language.
- Python 3.8 or higher
- pip (Python package installer)
-
Clone the repository to your local machine:
git clone https://github.com/hosamation/YouTube-Downloader.git
-
Navigate to the project directory:
cd YouTube-Downloader -
Install the required dependency:
pip install pytubefix
-
Run the script from your terminal:
python3 youtube_downloader.py
-
You will be presented with a menu of options:
YouTube Downloader ================== 1. Download a single YouTube video 2. Download a YouTube playlist 3. Download audio from a YouTube video 4. Download audio from a YouTube playlist 5. Download video subtitles 6. Download playlist subtitles ================== -
Enter the number corresponding to your desired action (e.g.,
1to download a single video). -
The script will then prompt you to enter the YouTube URL and the full path to the folder where you want to save the content.
-
The download will begin, and the script will print progress and completion messages to the console.
Contributions are welcome! If you have suggestions for improvements or encounter any issues, please feel free to open an issue or submit a pull request on the GitHub repository.
This project is licensed under the MIT License. See the LICENSE file for details.