Download YouTube videos as MP3 with video preview, ID3 metadata, and a beautiful web interface.
- Smart Search - Search videos by name or paste YouTube URLs
- Video Preview - Play videos directly in the application
- Audio Player - Listen to your downloaded MP3s with full controls
- Automatic ID3 Metadata - Title, artist, album, and embedded cover art
- MP3 Download - High quality (192kbps) with automatic conversion
- Termux Support - Works on Android with Termux
- Dark Mode - Modern and responsive design for all devices
# Clone the repository
git clone https://github.com/josevdr95new/PyTube-AudioHub.git
cd PyTube-AudioHub
# Install FFmpeg
# Ubuntu/Debian: sudo apt install ffmpeg
# macOS: brew install ffmpeg
# Windows: https://ffmpeg.org/download.html
# Create virtual environment and install dependencies
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
pip install -r requirements.txt
# Start the application
python app.py# Install Termux from F-Droid or Play Store
# Update and install Python
pkg update && pkg upgrade
pkg install python git ffmpeg
# Clone the repository
git clone https://github.com/josevdr95new/PyTube-AudioHub.git
cd PyTube-AudioHub
# Grant storage permissions
termux-setup-storage
# Install dependencies
pip install -r requirements.txt
# Start the application
python app.pyThe application will be available at: http://localhost:8000
- Open
http://localhost:8000in your browser - Type a video name or paste a YouTube URL
- Click Search
- To preview a video, click the play button
- To download, click "Download MP3"
- Files are saved in the
downloads/folder - Click the play button to listen to your downloaded MP3s
PyTube-AudioHub/
├── app.py # Main FastAPI server
├── requirements.txt # Python dependencies
├── README.md # English documentation
├── README_ES.md # Spanish documentation
├── services/ # Server logic
│ ├── __init__.py
│ ├── downloader.py # Download + ID3 metadata
│ ├── youtube.py # Search service
│ └── youtube_scraper.py # Video scraping
├── static/ # Frontend resources
│ ├── css/
│ │ └── style.css # Modern styles
│ └── js/
│ └── app.js # Interactive frontend
└── templates/
└── index.html # Complete web interface
| Category | Technology |
|---|---|
| Backend | FastAPI + Python |
| Download Engine | yt-dlp |
| Audio Processing | FFmpeg + Mutagen |
| Frontend | HTML5 + CSS3 + Vanilla JS |
| Communication | REST API + WebSockets |
- ✅ 192kbps MP3 download
- ✅ ID3 Metadata (TIT2, TPE1, TALB, APIC)
- ✅ Real-time progress via WebSockets
- ✅ Video search without API key
- ✅ Responsive design (mobile-friendly)
- ✅ Optimized dark theme
Contributions are welcome! Please:
- Fork the repository
- Create a branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This is an educational project created to learn about web development with FastAPI and Python.
This software is provided "as is" without any warranties.
Using this application to download YouTube content may violate YouTube's Terms of Service. The user is responsible for complying with applicable copyright laws in their country.
We are not responsible for any misuse of this tool.
⭐ If you like this project, don't forget to star it on GitHub!
Made with ❤️ by josevdr95
Repository: https://github.com/josevdr95new/PyTube-AudioHub