spotDL Manual

The complete command reference for spotDL — the open-source Spotify downloader. spotDL reads track metadata from Spotify, finds the matching audio on YouTube Music, and saves tagged audio files with album art and lyrics. Every command block below has a copy button.

Beginner Intermediate Advanced
00

What is spotDL

Read first

spotDL is a free, open-source command-line tool. Importantly, it does not rip protected audio out of Spotify itself. It uses your Spotify link only to read the song's metadata (title, artist, album, cover art), then downloads a matching audio track from YouTube Music and tags it. That distinction matters for both audio quality and the legal notes at the bottom of this page.

What you give it

Any Spotify URL — a track, album, playlist, or artist — or a plain search query like "artist - song". It also accepts YouTube links and Saavn links.

What you get back

Tagged audio files (MP3 by default; FLAC, OPUS, OGG, M4A, WAV available) with embedded album art, artist/album metadata, and synced lyrics where available.

Requirements

Python 3.9+ and FFmpeg. The Setup section below installs both. spotDL runs on macOS, Windows, and Linux.

01

Setup & Installation

Beginner

spotDL is a Python command-line program. The cleanest install path is pipx, which puts spotDL in its own isolated environment so it never collides with your other Python packages. Follow the steps for your operating system. You need FFmpeg too — spotDL uses it to convert audio.

macOS — install Homebrew (if you don't have it)

Homebrew is the standard macOS package manager. Skip if brew --version already works.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

macOS — install FFmpeg, pipx, then spotDL

Three commands. pipx ensurepath adds spotDL to your PATH; open a new terminal tab afterward.

brew install ffmpeg pipx
pipx ensurepath
pipx install spotdl

Windows — install via winget (PowerShell)

Run PowerShell as a normal user. This installs Python, FFmpeg, then spotDL.

winget install Python.Python.3.12
winget install Gyan.FFmpeg
pip install spotdl

Linux (Debian / Ubuntu)

Install Python, FFmpeg and pipx from apt, then spotDL via pipx.

sudo apt update && sudo apt install -y python3 python3-pip pipx ffmpeg
pipx ensurepath
pipx install spotdl

Don't have FFmpeg system-wide? Let spotDL fetch it

spotDL can download a private FFmpeg copy just for itself — handy if you can't or don't want to install it globally.

spotdl --download-ffmpeg

Verify it works

Print the version. If you see a version number, you're ready to download.

spotdl --version
Why pipx over pip? Modern Python installs (Homebrew, system Python) block global pip install to protect themselves. pipx sidesteps that by giving each CLI tool its own isolated virtual environment — install, upgrade, and uninstall cleanly with no conflicts.
02

AI Setup Prompt

Copy & paste

Not comfortable with a terminal? Hand this entire prompt to an AI coding assistant that can run commands on your computer (see the note below for what that means). It will install spotDL for you, check that it works, and — if it turns out it can't run commands — explain in plain English exactly what you need instead.

I want to install and use spotDL, the open-source Spotify downloader, on my computer. Please help me end to end.

FIRST, check your own capabilities: can you actually run shell/terminal commands on my computer right now (for example, do you have a Bash, shell, or command-execution tool)?

IF YES — you can run commands:
1. Detect my operating system (macOS, Windows, or Linux).
2. Check whether Python 3.9+, FFmpeg, and pipx are installed; install whatever is missing using the correct package manager for my OS (Homebrew on macOS, winget on Windows, apt/dnf/pacman on Linux).
3. Install spotDL with: pipx install spotdl  (or: pip install spotdl  if pipx is unavailable).
4. Verify the install by running: spotdl --version
5. Show me one example command to download a song, and offer to run a test download on a royalty-free or public-domain track to confirm everything works.
Explain each step in plain language as you go, and stop and ask me before doing anything that needs my confirmation.

IF NO — you cannot run commands on my computer (you can only chat):
Do NOT pretend to install anything. Instead, tell me clearly:
1. That spotDL is a command-line program, so it must be installed and run by something that has real access to my computer's terminal — a chat-only AI cannot do it.
2. That I have two good options: (a) open the Terminal app (macOS/Linux) or PowerShell (Windows) myself and paste in commands you give me, or (b) use an AI assistant that has terminal/command-line access — for example Claude Code, Cursor, or a similar coding agent running on my own machine.
3. Briefly, why this is: installing software, downloading files, and running spotDL all happen on my computer's operating system, which a website-based chat AI is sandboxed away from for security. An AI with terminal access is allowed to run those commands directly.
Then, give me the exact copy-paste commands for my operating system so I can run them myself in the Terminal, and walk me through them one at a time.
What "terminal access" means. A normal chat AI on a website lives in a sandbox and cannot touch your computer's files or run programs. Tools like Claude Code, Cursor, or other coding agents run on your own machine and are allowed to execute terminal commands — that's what spotDL needs. If your AI can't run commands, it will (thanks to the prompt above) just hand you the commands to paste into Terminal/PowerShell yourself.
03

Basic Downloads

Beginner

The core command is spotdl download (or just spotdl followed by a link — download is the default operation). Wrap every URL in quotes so your shell doesn't choke on special characters.

Download a single trackdownload

Paste any Spotify track URL. Saves to the current folder as MP3.

spotdl "https://open.spotify.com/track/..."
Download a whole albumdownload

An album URL grabs every track on the album.

spotdl download "https://open.spotify.com/album/..."
Download a playlistdownload

Public playlist URLs work directly. For your private playlists, see Config & the user-auth flag.

spotdl download "https://open.spotify.com/playlist/..."
Download an artist's entire catalogdownload

An artist URL pulls all their albums and singles. This can be large — be patient.

spotdl download "https://open.spotify.com/artist/..."
Download by search (no link needed)download

Don't have a link? Search by name. spotDL finds the closest match on Spotify, then downloads it.

spotdl download "Fleetwood Mac - Dreams"
Download several links at oncedownload

Pass multiple URLs separated by spaces — they're all queued.

spotdl download "URL_one" "URL_two" "URL_three"
04

Operations

Intermediate

Beyond download, spotDL has several other operations. The pattern is always spotdl <operation> <query>.

Operations
download
Find and download audio (the default).
save
Save metadata to a .spotdl file without downloading — a portable backup of a playlist.
url
Print the YouTube Music URL spotDL would use, without downloading.
sync
Mirror a playlist to a folder — adds new tracks, removes deleted ones. See the Sync section.
meta
Update tags/metadata on already-downloaded files without re-downloading audio.
web
Launch the local browser-based GUI.
Save a playlist as a portable filesave

Stores the whole tracklist + metadata in one .spotdl file. Download it later (even if the playlist changes) by passing that file back to download.

spotdl save "PLAYLIST_URL" --save-file my_list.spotdl
Download from a saved filedownload

Feed a previously saved .spotdl file straight back in.

spotdl download my_list.spotdl
Just show the source URLurl

Useful for debugging a bad match — see which YouTube track spotDL picked.

spotdl url "TRACK_URL"
Launch the web GUIweb

Prefer clicking to typing? This opens a local web interface in your browser.

spotdl web
05

Format & Quality

Intermediate

Choose your audio format and bitrate. A note on "quality": spotDL's source is YouTube Music, which is lossy. Exporting to FLAC does not create true lossless audio from a lossy source — it just rewraps it. Use FLAC only if a downstream tool requires it; otherwise MP3 320k or the default is best.

Pick the output format--format

Options: mp3 (default), flac, ogg, opus, m4a, wav.

spotdl download "URL" --format flac
Set the bitrate--bitrate

e.g. 320k, 256k, or disable to copy the source stream untouched (fastest, no re-encode).

spotdl download "URL" --bitrate 320k
Best quality, no re-encodecombo

Grab the highest-quality source stream as-is — fastest and avoids quality loss from re-encoding.

spotdl download "URL" --bitrate disable
Run more downloads in parallel--threads

Speed up large playlists by downloading several tracks at once (default is 4).

spotdl download "PLAYLIST_URL" --threads 8
06

Output & File Names

Intermediate

The --output flag controls where files go and how they're named, using template variables in curly braces. Build the folder structure you want automatically.

Common template variables
{title}
Song title
{artist}
Primary artist
{artists}
All credited artists
{album}
Album name
{track-number}
Position on the album
{year}
Release year
{genre}
Genre
{playlist}
Source playlist name
Organize by artist and album--output

Creates Artist/Album/01 - Title.mp3 style folders automatically.

spotdl download "URL" --output "{artist}/{album}/{track-number} - {title}.{output-ext}"
Save to a specific folder--output

Point everything at one directory (e.g. your Music folder).

spotdl download "URL" --output "~/Music/{artist} - {title}.{output-ext}"
Group a playlist into its own folder--output

Keeps each playlist's tracks neatly separated.

spotdl download "PLAYLIST_URL" --output "{playlist}/{artist} - {title}.{output-ext}"
Skip songs you already have--restrict

Use a skip-existing scan so re-runs don't re-download. spotDL skips matching files by default; force overwrite with --overwrite force.

spotdl download "PLAYLIST_URL" --overwrite skip
07

Metadata & Lyrics

Intermediate

spotDL embeds tags, album art, and lyrics automatically. These flags let you fine-tune the sources and fix tags on files you already downloaded.

Choose lyrics providers--lyrics

Order of preference — spotDL tries each in turn. Options include genius, musixmatch, azlyrics, synced.

spotdl download "URL" --lyrics genius musixmatch
Fix tags on existing filesmeta

Re-apply correct metadata/art to already-downloaded files — no audio re-download.

spotdl meta "PLAYLIST_URL" --output "~/Music"
Generate an .lrc lyrics file--generate-lrc

Saves synced lyrics as a separate .lrc file alongside each track — great for players that show scrolling lyrics.

spotdl download "URL" --generate-lrc
Skip album-art embedding--no-album-art

Smaller files, faster downloads, when you don't need cover images.

spotdl download "URL" --skip-album-art
08

Sync Playlists

Advanced

sync keeps a local folder in lockstep with a Spotify playlist. The first run creates a sync file; later runs add tracks added to the playlist and delete tracks removed from it. Perfect for a cron job or a "keep my library current" workflow.

Set up a syncsync

Create the sync file once. Re-run the same command anytime to update.

spotdl sync "PLAYLIST_URL" --save-file playlist.sync.spotdl
Run the sync (update the folder)sync

Pass the sync file back in. Adds new, removes deleted, leaves the rest.

spotdl sync playlist.sync.spotdl
sync deletes files. When a track is removed from the Spotify playlist, sync deletes the local file to match. Keep synced folders separate from your hand-curated library so nothing precious gets removed.
09

Config & Updating

Advanced

Save your favorite flags once in a config file so you never retype them, and keep spotDL current.

Generate a config file--generate-config

Creates an editable config.json in your spotDL settings folder. Set defaults for format, bitrate, output, threads, etc.

spotdl --generate-config
Use your config every run--config

Apply the saved config automatically.

spotdl download "URL" --config
Download a private playlist--user-auth

Log in to Spotify in your browser so spotDL can read your private/liked playlists.

spotdl download "saved" --user-auth
Update spotDLpipx

Pull the latest version. Use the matching command for how you installed it.

# installed with pipx:
pipx upgrade spotdl
# installed with pip:
pip install --upgrade spotdl
10

Troubleshooting

Fixes

The most common snags and their fixes.

"command not found: spotdl"

pipx hasn't been added to your PATH, or you need a fresh terminal. Run the ensurepath step, then open a new tab.

pipx ensurepath
# then close and reopen your terminal
"FFmpeg was not found"

Let spotDL install its own private copy, then point at it automatically.

spotdl --download-ffmpeg
Wrong song / bad match downloaded

Force spotDL to prefer exact YouTube Music matches and only accept high-confidence results.

spotdl download "URL" --audio youtube-music --only-verified-results
Rate-limited or failing downloads

Lower the thread count and add cookies if you have YouTube Premium. First, make sure you're on the latest version (fixes most breakage).

pipx upgrade spotdl
spotdl download "URL" --threads 1
See the full flag list

When in doubt, the built-in help lists every available option.

spotdl --help

spotDL Manual · built with the personal-html design system

Not affiliated with Spotify or spotDL · v4 reference · 2026