Match streaming playlists to your DJ library
Project description
setlist-sync
Match streaming playlists against your local DJ library and create playlists in your DJ software — with cues, loops, and all metadata intact.
The Problem
You're a DJ. A client sends you a Spotify playlist with 50 song requests for their event. You need to:
- Figure out which songs you already have
- Find them in your library across thousands of tracks
- Create a playlist in your DJ software
- Download only the songs you're missing
Without this tool, you'd manually search each song, accidentally download duplicates, and lose your carefully set cue points and loops on re-downloaded tracks.
The Solution
setlist-sync "https://open.spotify.com/playlist/..." --playlist-name "Wedding Jan & An"
In under a second, setlist-sync:
- Fetches the playlist from Spotify (no API key or Premium needed)
- Fuzzy-matches every track against your DJ library (4800+ tracks in 0.4s)
- Creates a playlist in your DJ software with your existing tracks — cues, loops, BPM, and all metadata preserved
- Reports which tracks you're missing so you only download what you need
Loaded library: 4820 tracks
Matching complete: 43/50 tracks found in library
Matched in 0.4s
Done! 43/50 tracks matched, 7 unmatched.
Unmatched tracks:
- Rick Astley - Never Gonna Give You Up
- Darude - Sandstorm
Features
- Spotify URL input — paste any public playlist link, no API key required
- CSV input — also accepts CSV files (e.g. from Exportify)
- Fuzzy matching — handles spelling differences, remix tags, featured artists, etc.
- DJ software integration — writes playlists directly to djay Pro and Rekordbox
- File-based output — alternatively copies matched files to an event folder with M3U playlist
- Smart normalization — strips
(feat. ...),(Remastered),- Radio Editetc. before matching - Fast — matches 50 tracks against 5000 in under a second using rapidfuzz
Installation
pip install setlist-sync
Requires Python 3.10+.
Development install
git clone https://github.com/mathiassp/setlist-sync.git
cd setlist-sync
python -m venv venv
source venv/bin/activate
pip install -e .
Usage
djay Pro mode (default)
Creates a playlist directly in your DJ software's database. Close your DJ software before running.
[!WARNING] Close your DJ software before running — setlist-sync writes directly to the database.
setlist-sync "https://open.spotify.com/playlist/..." --playlist-name "Wedding Jan & An"
File output mode
Copies matched files to an output folder with an M3U playlist.
setlist-sync "https://open.spotify.com/playlist/..." --playlist-name "Wedding" --files
CSV input
setlist-sync playlist.csv --playlist-name "Birthday Party"
[!TIP] Use
--dry-runto preview matches without writing anything.
Options
| Flag | Description |
|---|---|
--playlist-name |
Name for the created playlist (default: Spotify playlist name) |
--rekordbox [XML] |
Use Rekordbox instead of djay. Without path: reads database directly. With path: uses XML file |
--files |
Copy matched files to an output folder with M3U playlist |
--threshold |
Match sensitivity 0-100 (default: 85) |
--dry-run |
Show what would happen without writing |
--handle-duplicates |
Interactively choose between multiple library matches per track |
--djay-db PATH |
Custom path to djay Pro database (default: ~/Music/djay/djay Media Library.djayMediaLibrary/MediaLibrary.db) |
--rekordbox-output |
Output path for Rekordbox XML mode (default: {input}_synced.xml) |
--music-dir |
Music folder path for --files mode (default: ~/Music) |
--symlink |
Use symlinks instead of copies in --files mode |
How It Works
Spotify URL ─→ spotify_client ─→ Track list (title + artist)
│
┌─────────────────────────┤
│ │
djay database │ Rekordbox database │ ~/Music folder
djay/library│ rekordbox/library │ library_scanner
│ │
└────────────┬────────────┘
│
matcher (fuzzy match)
│
┌────────────┼────────────┐
│ │ │
djay/playlist rekordbox/ output
(djay Pro DB) playlist (files + M3U)
(Rekordbox DB/XML)
Matching
Uses rapidfuzz for fuzzy string matching with weighted scoring:
- Title similarity: 60% weight
- Artist similarity: 40% weight
- Normalizes strings before matching: strips remix/edit tags, featured artists, punctuation
DJ Software Integration
Writes directly to your DJ software's database. For djay Pro, this uses a clone-based approach to handle the proprietary TSAF format. For Rekordbox, it uses pyrekordbox to access the encrypted database. A backup is automatically created before every write.
Supported DJ Software
| Software | Versions | Platform | Read Library | Write Playlists | Status |
|---|---|---|---|---|---|
| djay Pro | 5.x | macOS | Yes | Yes | Supported |
| Rekordbox | 6.x / 7.x | macOS, Windows | Yes | Yes | Supported |
| Serato DJ | — | — | — | — | Coming soon |
| Traktor | — | — | — | — | Coming soon |
Note: setlist-sync was developed and tested with djay Pro 5 and Rekordbox 7. Older versions may work but have not been tested. If you try it with a different version, please open an issue and let us know how it went!
Supported Input Sources
- Spotify — public playlist URLs (no account needed)
- CSV — any CSV with track name and artist columns
Planned
- Tidal
- Apple Music
- YouTube Music
Limitations
- Playlist names are limited to 34 characters in djay mode
- Your DJ software must be closed when writing playlists
- djay Pro integration is macOS only; Rekordbox works on macOS and Windows
- Matching accuracy depends on how tracks are tagged in your library
Contributing
Issues and PRs welcome. If you use different DJ software and want to add support, open an issue to discuss the approach.
License
MIT
If this saved you time, consider giving it a star.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file setlist_sync-0.1.1.tar.gz.
File metadata
- Download URL: setlist_sync-0.1.1.tar.gz
- Upload date:
- Size: 25.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99226b62e5626dca24b1fd5fe173c529c3609b0ed7abbfbadd3f24c15007661f
|
|
| MD5 |
72760605fec920fe5147dea0b0c75f25
|
|
| BLAKE2b-256 |
9ac6c2ee5458d151bab28b49b061c5278061e111138b03bcb11196632d6fd435
|
File details
Details for the file setlist_sync-0.1.1-py3-none-any.whl.
File metadata
- Download URL: setlist_sync-0.1.1-py3-none-any.whl
- Upload date:
- Size: 27.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
957d5b45e8763992df6049cbd5398dd9691a029d3121009a07c3c3314cf3c836
|
|
| MD5 |
2ffaeaedb47edfbb555ee33b831df6d8
|
|
| BLAKE2b-256 |
0a1d9ed3283e8b5b471f78ff75d72a382a33147405edb5f50b2e290f3344dbc9
|