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.
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.
What is spotDL
Read firstspotDL 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.
Tagged audio files (MP3 by default; FLAC, OPUS, OGG, M4A, WAV available) with embedded album art, artist/album metadata, and synced lyrics where available.
Python 3.9+ and FFmpeg. The Setup section below installs both. spotDL runs on macOS, Windows, and Linux.
Maintained on GitHub at spotDL/spotify-downloader. Docs at spotdl.readthedocs.io.
Setup & Installation
BeginnerspotDL 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-ffmpegVerify it works
Print the version. If you see a version number, you're ready to download.
spotdl --versionpip 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.AI Setup Prompt
Copy & pasteNot 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.
Basic Downloads
BeginnerThe 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.
Paste any Spotify track URL. Saves to the current folder as MP3.
spotdl "https://open.spotify.com/track/..."
An album URL grabs every track on the album.
spotdl download "https://open.spotify.com/album/..."
Public playlist URLs work directly. For your private playlists, see Config & the user-auth flag.
spotdl download "https://open.spotify.com/playlist/..."
An artist URL pulls all their albums and singles. This can be large — be patient.
spotdl download "https://open.spotify.com/artist/..."
Don't have a link? Search by name. spotDL finds the closest match on Spotify, then downloads it.
spotdl download "Fleetwood Mac - Dreams"
Pass multiple URLs separated by spaces — they're all queued.
spotdl download "URL_one" "URL_two" "URL_three"
Operations
IntermediateBeyond download, spotDL has several other operations. The pattern is always spotdl <operation> <query>.
.spotdl file without downloading — a portable backup of a playlist.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
Feed a previously saved .spotdl file straight back in.
spotdl download my_list.spotdlUseful for debugging a bad match — see which YouTube track spotDL picked.
spotdl url "TRACK_URL"
Prefer clicking to typing? This opens a local web interface in your browser.
spotdl webFormat & Quality
IntermediateChoose 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.
Options: mp3 (default), flac, ogg, opus, m4a, wav.
spotdl download "URL" --format flac
e.g. 320k, 256k, or disable to copy the source stream untouched (fastest, no re-encode).
spotdl download "URL" --bitrate 320k
Grab the highest-quality source stream as-is — fastest and avoids quality loss from re-encoding.
spotdl download "URL" --bitrate disable
Speed up large playlists by downloading several tracks at once (default is 4).
spotdl download "PLAYLIST_URL" --threads 8
Output & File Names
IntermediateThe --output flag controls where files go and how they're named, using template variables in curly braces. Build the folder structure you want automatically.
Creates Artist/Album/01 - Title.mp3 style folders automatically.
spotdl download "URL" --output "{artist}/{album}/{track-number} - {title}.{output-ext}"
Point everything at one directory (e.g. your Music folder).
spotdl download "URL" --output "~/Music/{artist} - {title}.{output-ext}"
Keeps each playlist's tracks neatly separated.
spotdl download "PLAYLIST_URL" --output "{playlist}/{artist} - {title}.{output-ext}"
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
Metadata & Lyrics
IntermediatespotDL embeds tags, album art, and lyrics automatically. These flags let you fine-tune the sources and fix tags on files you already downloaded.
Order of preference — spotDL tries each in turn. Options include genius, musixmatch, azlyrics, synced.
spotdl download "URL" --lyrics genius musixmatch
Re-apply correct metadata/art to already-downloaded files — no audio re-download.
spotdl meta "PLAYLIST_URL" --output "~/Music"
Saves synced lyrics as a separate .lrc file alongside each track — great for players that show scrolling lyrics.
spotdl download "URL" --generate-lrc
Smaller files, faster downloads, when you don't need cover images.
spotdl download "URL" --skip-album-art
Sync Playlists
Advancedsync 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.
Create the sync file once. Re-run the same command anytime to update.
spotdl sync "PLAYLIST_URL" --save-file playlist.sync.spotdl
Pass the sync file back in. Adds new, removes deleted, leaves the rest.
spotdl sync playlist.sync.spotdlConfig & Updating
AdvancedSave your favorite flags once in a config file so you never retype them, and keep spotDL current.
Creates an editable config.json in your spotDL settings folder. Set defaults for format, bitrate, output, threads, etc.
spotdl --generate-configApply the saved config automatically.
spotdl download "URL" --config
Log in to Spotify in your browser so spotDL can read your private/liked playlists.
spotdl download "saved" --user-auth
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
Troubleshooting
FixesThe most common snags and their fixes.
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
Let spotDL install its own private copy, then point at it automatically.
spotdl --download-ffmpegForce spotDL to prefer exact YouTube Music matches and only accept high-confidence results.
spotdl download "URL" --audio youtube-music --only-verified-results
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
When in doubt, the built-in help lists every available option.
spotdl --helpLegal & Ethics
ReadA short, honest note so you can make informed choices.
spotDL Manual · built with the personal-html design system
Not affiliated with Spotify or spotDL · v4 reference · 2026