Skip to main content

A lightweight CLI tool to download audio from YouTube playlists

Project description

yt-playlist-dl

A lightweight CLI tool to download audio from YouTube playlists and videos. Perfect for Termux on Android!

Features

  • 🎵 Download audio-only from YouTube playlists and individual videos
  • 📦 Lightweight with minimal dependencies (just yt-dlp)
  • 🚀 Simple command-line interface
  • 📱 Works great on Android via Termux
  • 🎚️ Customizable audio format and quality

Installation

From PyPI (once published)

pip install yt-playlist-dl

From source

git clone https://github.com/yourusername/yt-playlist-dl.git
cd yt-playlist-dl
pip install .

On Termux (Android)

pkg install python ffmpeg
pip install yt-playlist-dl

Usage

Download a playlist to the current directory:

yt-playlist-dl "https://www.youtube.com/playlist?list=..."

Download to a specific directory:

yt-playlist-dl -o ~/Music "https://www.youtube.com/playlist?list=..."

Download in different format with custom quality:

yt-playlist-dl -f m4a -q 256 "https://www.youtube.com/playlist?list=..."

Download a single video:

yt-playlist-dl "https://youtu.be/dQw4w9WgXcQ"

Download private playlists (like Liked videos) - OAuth login:

yt-playlist-dl --login "https://www.youtube.com/playlist?list=LL"
# Opens browser or shows URL to authenticate with your Google account

Options

positional arguments:
  url                   YouTube playlist or video URL

optional arguments:
  -h, --help            show this help message and exit
  -o OUTPUT, --output OUTPUT
                        Output directory (default: current directory)
  -f {mp3,m4a,opus,wav,flac}, --format {mp3,m4a,opus,wav,flac}
                        Audio format (default: mp3)
  -q QUALITY, --quality QUALITY
                        Audio quality in kbps (default: 192)
  -c COOKIES, --cookies COOKIES
                        Path to cookies.txt file for authentication
  --login               Login to YouTube using OAuth (for private playlists)
  -v, --version         show program's version number and exit

Requirements

  • Python 3.7+
  • yt-dlp
  • FFmpeg (for audio conversion)

On Termux, install FFmpeg with:

pkg install ffmpeg

License

MIT License - feel free to use and modify!

Contributing

Pull requests welcome! For major changes, please open an issue first.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ytplaylist_downloader-0.1.2.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ytplaylist_downloader-0.1.2-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file ytplaylist_downloader-0.1.2.tar.gz.

File metadata

  • Download URL: ytplaylist_downloader-0.1.2.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for ytplaylist_downloader-0.1.2.tar.gz
Algorithm Hash digest
SHA256 79e3edc75a34f2f8023075271520eaa83b96e8434cad899f4e3a79e154ab8bc8
MD5 f280657cd88335ecbdc1b2fa762a5831
BLAKE2b-256 77fcaf1167e28572a54ba0e0f41e5738cf40baba89865607883b7acd133a441f

See more details on using hashes here.

File details

Details for the file ytplaylist_downloader-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for ytplaylist_downloader-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 48bd64286723ca0bd654e71785929e8a89c4ae3da300d4d5e5b9666c00341907
MD5 fa29df82b95958b90060dc3280da0cdf
BLAKE2b-256 6c93303577fab8b037f93054671c266e33f378199981e6810b4c4018375cfd9c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page