A powerful and efficient Python tool for downloading TikTok videos with advanced features and error handling.
- 📥 Download TikTok videos in highest quality available
- 🎯 Custom filename support with timestamps
- 🗂️ Automatic directory management
- 🔄 Progress tracking with real-time updates
- 🛡️ Robust error handling and validation
- 🌐 Browser cookie integration for better compatibility
- 📝 Detailed logging and status reporting
- Python 3.7 or higher
- Required packages:
yt-dlp>=2023.3.4 typing>=3.7.4
- Clone the repository:
git clone https://github.com/vgvr0/TikTok-Video-Downloader-using-Python-and-yt-dlp
cd tiktok-downloader-pro
- Create a virtual environment (optional but recommended):
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
- Install dependencies:
pip install -r requirements.txt
from tiktok_downloader import TikTokDownloader
# Initialize downloader
downloader = TikTokDownloader()
# Download single video
video_url = "https://www.tiktok.com/@username/video/1234567890"
downloader.download_video(video_url)
# Custom save location and filename
downloader = TikTokDownloader(save_path='my_tiktoks')
downloader.download_video(video_url, custom_name="dance_video")
# Download multiple videos
urls = [
"https://www.tiktok.com/@user1/video/1234567890",
"https://www.tiktok.com/@user2/video/0987654321"
]
for url in urls:
downloader.download_video(url)
Parameter | Description | Default |
---|---|---|
save_path | Directory to save videos | 'tiktok_videos' |
custom_name | Custom name for the video | None |
use_cookies | Use browser cookies | True |
quiet_mode | Suppress progress output | False |
Downloading: 45.2% at 1.2 MB/s ETA: 00:15
Download completed, finalizing...
Video successfully downloaded: my_tiktoks/dance_video_20240106_123045.mp4
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature
) - Commit your changes (
git commit -m 'Add some AmazingFeature'
) - Push to the branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- yt-dlp for the amazing download capabilities
- TikTok for providing the content platform
- All contributors and users of this project
This tool is for educational purposes only. Make sure to comply with TikTok's terms of service and respect content creators' rights when using this tool.
If you encounter any issues or have questions:
- Open an issue on GitHub
- Contact us via Telegram
- Check our documentation