Skip to main content

subsnip logo

subsnip

Your playlists on any MP3 player: the official recordings, with proper names, album info, cover art and synced lyrics.

tests PyPI MIT license Python 3.8+ 320k MP3 Linux, macOS, Windows

Support subsnip on Ko-fi Join the Discord

Inspired by spotDL, but strict: if subsnip can't confirm a song is the official release, it skips it instead of guessing.


$ subsnip download ~/Downloads/my_playlist.csv
3 already downloaded, 4 to go
[2/7] Lil Peep - feelz  ok
[3/7] Poshlaya Molly - ШКОЛЬНИК  ok
[5/7] Kino - Пачка сигарет  ok
[4/7] Che - wtf  ok
done

Installation

subsnip needs Python 3.8+, FFmpeg and Node.js.

pip install subsnip
subsnip -h

Update with pip install -U subsnip. If pip says "externally-managed-environment" (many Linux distros), use pipx install subsnip instead. If subsnip isn't found afterwards, use python3 -m subsnip (Windows: python -m subsnip), or add pip's scripts folder to your PATH.

Other options

  • From source:
    git clone https://gitlab.com/ddddaaaattttoooo/subsnip
    cd subsnip
    pip install -r requirements.txt
    python3 subsnip.py -h
    

Installing FFmpeg

FFmpeg converts and tags the audio.

  • Windows: winget install Gyan.FFmpeg
  • macOS: brew install ffmpeg
  • Linux: your package manager, e.g. sudo apt install ffmpeg

Installing Node.js

yt-dlp uses Node.js to read YouTube pages.

  • Windows: winget install OpenJS.NodeJS
  • macOS: brew install node
  • Linux: your package manager, e.g. sudo apt install nodejs

Usage

Export your playlist as CSV with Exportify, then:

subsnip [operation] [CSV] [FOLDER]

FOLDER defaults to ~/Music/<csv name>. Run subsnip -h for help and subsnip -V for the version.

Supported operations

  • download: downloads every song in the playlist, skipping songs you already have.
    • Usage: subsnip download my_playlist.csv
    • Option: --workers N, songs downloaded at once (default 3)
  • check: compares every song's tags and cover with the playlist. Changes nothing.
    • Usage: subsnip check my_playlist.csv
  • retag: rewrites tags, cover and lyrics. The audio is untouched.
    • Usage: subsnip retag my_playlist.csv

Output

~/Music/my_playlist/
├── Artist - Song.mp3
├── Artist - Song.lrc
├── my_playlist.m3u8   playlist in your order
├── failed.txt         songs with no exact match (only if there are any)
└── skip.txt           your own list of songs to skip (optional)

Copy the folder to your player. Players with synced lyrics read the .lrc files; others show the lyrics embedded in the MP3.

Skipping songs

Create skip.txt in the music folder:

# never download this one
Some Artist - Some Song
# use my own file instead (it takes this song's place in the playlist)
Other Artist - Other Song = My Artist - My Version

Matching and Audio Quality

subsnip finds each song in this order and stops at the first exact match:

  1. ISRC, the code that identifies one exact recording, searched on YouTube Music.
  2. Artist and title on YouTube Music. Artists written in other alphabets (Cyrillic and more) work too.
  3. The artist's own SoundCloud upload.

Every match must be an official release by the right artist, within 3 seconds of the playlist's length. Fan uploads, music videos, sped-up edits and live versions are never used. Songs with no exact match go to failed.txt.

Metadata and lyrics

Title, all artists, album, album artist, year, ISRC, label, genre, explicit flag and the 640×640 album cover. Lyrics come from LRCLIB as a synced .lrc file plus lyrics embedded in the MP3. Every song is checked right after download.

Audio Quality

Everything is saved as 320 kbps MP3, one quality for the whole library, about 140 MB per hour of music.

Note subsnip is for personal use. It downloads from YouTube Music and SoundCloud through yt-dlp and never touches Spotify's audio or any DRM-protected stream. Only download music you have the right to, and follow the terms of the services you use.

Troubleshooting

  • A song is in failed.txt. No official upload with the same length was found. That's on purpose: subsnip won't guess. Add your own copy and list it in skip.txt.
  • "YouTube rate limit hit". Wait about an hour and run the same command again. Finished songs are skipped.
  • macOS: SSL certificate errors. Run "Install Certificates.command" in your Python folder (python.org installs only).
  • Old yt-dlp. Update with pip install -U yt-dlp, or point the YTDLP_PATH environment variable at a nightly build.

Why a CSV and not a link? A public playlist page only shows the first 100 songs, and reading playlists directly needs a developer key. Exportify gives the full list with ISRCs, genres and labels in one file.

Contributing

Found a bug or have an idea? Open an issue or a merge request. Run the tests first:

python3 test_subsnip.py

Credits

Made by ddddaaaattttoooo.

Built on yt-dlp, mutagen, FFmpeg, LRCLIB and Exportify. Inspired by spotDL.

License

This project is licensed under the MIT license.

Metadata

Release files for subsnip 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for subsnip 1.0.0
File Size Uploaded Provenance Actions
subsnip-1.0.0.tar.gz 11.9 kB Without provenance Details for subsnip-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for subsnip 1.0.0
File Interpreter ABI Platform Actions
subsnip-1.0.0-py3-none-any.whl Python 3 none any Details for subsnip-1.0.0-py3-none-any.whl

Total release size: 25.0 kB

Release files / subsnip-1.0.0.tar.gz

Download URL subsnip-1.0.0.tar.gz
Size 11.9 kB
Tags Source
SHA-256 checksum
How to use checksums
f18a075998acf19a00d0d9569bd0ad10cd5b0bb48435b32562beffd1b83628e3
BLAKE2b-256 checksum
How to use checksums
d5122a3e8d67d5333cdea69fc2601f5976d60b057dcd7db08fa72fb57622445f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Release files / subsnip-1.0.0-py3-none-any.whl

Download URL subsnip-1.0.0-py3-none-any.whl
Size 13.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a9a0b403bed486c36658210f7613d8a6e0d67b0b927853761d3fe85cba025fd8
BLAKE2b-256 checksum
How to use checksums
2a156bdcf89c6f23ec43d43c2c94d4c6100652d8244fb57d5a391054b26ec4f1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Security for subsnip 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page