This is a simple Python GUI application for downloading YouTube videos using youtube_dl and Tkinter.
- GUI-based YouTube video downloader
- Allows browsing and selecting the download directory
- Simple, minimal interface
- Downloads videos in their original format
- Python 3.x
- Packages:
youtube_dltkinter(comes pre-installed with Python on most systems)os(built-in)
Install youtube_dl:
pip install youtube_dl- Clone or download this script.
- Run the script:
python youtube_downloader.py- In the GUI:
- Paste the YouTube video link.
- Select a destination folder.
- Click DOWNLOAD video.
youtube_downloader.py # Main application script
- CreateWidgets(): Creates and places Tkinter widgets.
- Browse(): Lets you choose a folder to save the downloaded file.
- Download(): Uses
youtube_dlto download the YouTube video. - paste(): Placeholder function for clipboard paste (not used in current version).
- Enter a YouTube link in the YOUTUBE LINK field.
- Click BROWSE to choose where the file should be saved.
- Click DOWNLOAD video to start downloading.
- Once complete, a SUCCESS message will pop up.
- This version downloads the video in its default available format.
- To customize download options (e.g., MP3, resolution, etc.), modify the
audDWLDoptdictionary in the code.
Example for downloading audio as MP3:
audDWLDopt = {
'format': 'bestaudio/best',
'postprocessors': [{
'key': 'FFmpegExtractAudio',
'preferredcodec': 'mp3',
'preferredquality': '192',
}]
}