The YouTube Converter is a powerful and easy-to-use desktop application designed to help users download videos, audio, and entire playlists from YouTube. With its intuitive graphical interface, users can quickly convert YouTube content to various formats, including MP3 for audio and MP4 for video, without needing any technical expertise. Whether you're downloading a single video or an entire playlist, the YouTube Converter handles everything in the background seamlessly.
- Video Downloads: Download YouTube videos in the highest available resolution.
- Audio Downloads: Convert YouTube videos to MP3 format and download them.
- Playlist Downloads: Download entire playlists in either audio or video formats.
- Automatic Audio/Video Merging: Uses FFmpeg to merge video and audio streams.
- User-Friendly GUI: Simplified, intuitive interface that requires no command-line interaction.
- Standalone Executable: No need to install Python or external dependencies—everything is bundled into one executable file.
If you're working in development mode, you need to install some dependencies via pip
. However, FFmpeg is already included in the project in a zipped format (ffmpeg.zip
), so no need to install it manually. Simply unzip the ffmpeg.zip
file as instructed below.
pytubefix==7.3.0
pytubefix
is the only external library that needs to be installed because all other modules (liketkinter
,subprocess
,os
,threading
, etc.) are part of Python's standard library.- You don't need to install FFmpeg separately, as it’s included in the project as
ffmpeg.zip
, which needs to be unzipped in both theffmpeg/
folder for development mode.
Install the required libraries using:
pip install -r requirements.txt
Whether you're a regular user or developer, you can run the application without any additional setup. Just follow these steps:
-
Download the Application
Download the latest release from the release page or directly using this link. -
Unzip the File
Extract the contents of the downloaded ZIP file. -
Run the Application
Open the extracted folder and double-clickmain.exe
to launch the YouTube Converter.
If you want to run the project in script mode for development purposes, follow the steps below:
-
Download or Clone the Repository
You can either download the entire project archive from the repository or clone it using the following command:git clone https://github.com/Glooring/youtube-converter.git cd youtube-converter
-
Install Dependencies
Install the required dependencies usingpip
:pip install -r requirements.txt
-
Unarchive
ffmpeg.zip
Inside the project folder, navigate to the following path:
helpers/ffmpeg/
.
You'll find a file namedffmpeg.zip
. Unzip this file to ensure thatffmpeg.exe
is available for the application to function properly.After unarchiving, the folder structure should look like this:
YouTube-Converter/ └── helpers/ # Folder containing helper modules └── ffmpeg/ # FFmpeg folder (for development mode └── ffmpeg.exe
-
Run the Application
Once theffmpeg.exe
is properly placed, you’re ready to run the application:python main.py
Once the application is launched, you’ll see three options in the main interface:
-
Simple link to audio: Download an audio file (MP3) from a YouTube video.
-
Simple link to video: Download the preferred resolution video from a YouTube video link.
-
Playlist link: Download an entire YouTube playlist as either audio or video, with videos in the highest available resolution. A list of all YouTube links and titles will be generated in the same folder where the files are downloaded.
-
Click on "Simple link to audio": This opens a new window for audio download.
-
Enter the YouTube video link: Paste the YouTube link into the input field.
-
Select the folder: Choose where you want to save the MP3 file.
-
Download progress: A progress bar will show the download and conversion status.
-
Completion: Once complete, the MP3 file will be saved in the selected folder.
-
Click on "Simple link to video": Opens the video download window.
-
Enter the YouTube video link: Paste the video link.
-
Select the folder: Choose where to save the video file.
-
Select the resolution: Choose from available resolutions (e.g., 1080p, 720p).
-
Download progress: A progress bar will show the download and conversion status.
-
Completion: The video and audio streams are downloaded, merged, and saved as an MP4 file.
-
Click on "Playlist link": This opens the playlist download window.
-
Enter the playlist URL: Paste the link of the playlist.
-
Choose download type: Select either MP3 (audio) or MP4 (video) for the entire playlist.
-
Select the folder: Choose where to save the playlist files.
-
Download process: The application downloads and processes each file in the playlist, showing progress for each.
-
Completion: Once complete, the Playlist folder will be saved in the selected folder.
The project is divided into several components for better organization and modularity. The overall structure is:
YouTube-Converter/
│
├── helpers/ # Folder containing helper modules
│ ├── ffmpeg/ # FFmpeg folder (for development mode
│ │ └── ffmpeg.exe # FFmpeg executable (unzip ffmpeg.zip here))
│ ├── audio_helper.py # Handles audio downloads and conversion
│ ├── video_helper.py # Manages video downloads and resolution selection
│ ├── playlist_helper.py # Handles playlist downloads (both video and audio)
│ └── utils.py # Utility functions (file sanitization, ffmpeg paths, etc.)
├── screenshots # Folder containing screenshots for the README
├── LICENSE # MIT License
├── README.md # Project documentation (this file)
├── main.py # Main script to launch the application
└── requirements.txt # Python dependencies for development purposes
For developers interested in building the standalone executable (main.exe
), we use PyInstaller to package the project. Below are the steps:
Make sure the project structure is correct with all the necessary helper modules and dependencies.
Use the following command to create the main.exe
executable:
pyinstaller --onedir --name main --hidden-import=helpers.audio_helper --hidden-import=helpers.playlist_helper --hidden-import=helpers.video_helper --hidden-import=helpers.utils --noconsole main.py
This will create a dist/
folder containing a main/
directory, which holds the main.exe
executable along with the necessary dependencies from the _internal
folder.
Before running the executable, unzip the ffmpeg.zip
file located in dist/main/_internal/helpers/ffmpeg/
to ensure that ffmpeg.exe
is available for the application to use.
- Python 3.7+: The primary programming language for the application.
- pytube: To interact with YouTube for downloading videos and playlists.
- tkinter: For creating the graphical user interface (GUI).
- ffmpeg: A multimedia tool for handling audio and video processing (bundled in the release).
- ffmpeg-python: Python wrapper for interacting with FFmpeg for video/audio merging.
Contributions are welcome! If you'd like to contribute:
- Fork the repository.
- Create a new branch (
feature/your-feature-name
). - Make your changes.
- Submit a pull request.
This project is licensed under the MIT License. See the LICENSE
file for more details.
The YouTube Converter is a powerful yet user-friendly tool that simplifies the process of downloading and converting YouTube content. Whether you’re downloading a single video, converting audio to MP3, or downloading entire playlists, the tool’s straightforward GUI makes it accessible to all users. With built-in FFmpeg support and the ability to run as a standalone executable, it's a versatile solution for managing YouTube downloads.