Spotify CSV Exporter - Project

1 minute read

  1 minute read

This tool automates the process of exporting Spotify playlists and favorite songs in an organized manner, generating CSV files. It leverages the Sportify project to accomplish this.

Additionally, it provides the flexibility to seamlessly migrate to other platforms or re-import the playlists back into Spotify, ensuring a smooth transition.

Can run on both Windows and Linux

!! At no time is the information (credentials) used in the script are recompiled.!!

Requirements & Installation

To use this tool, you need to have the Selenium module installed. You can install it by running the following command in your terminal:

pip install selenium requests

After that, you can download the repository by running the following commands:

git clone
cd Spotify-CSV-Exporter


This script is compatible with both Windows and Linux operating systems and requires Python 3.


The script’s configuration is defined in the config_spotify.json file, which has the following structure:

    "DOWNLOAD_PATH": "C:\\path\\to\\your\\backups",
    "DEBUG_PATH": "C:\\path\\to\\your\\logs",
  • DOWNLOAD_PATH: the path where the downloaded files will be stored.
  • DEBUG_PATH: the path where the script logs will be saved.
  • EMAIL: the email address associated with the Spotify account.
  • PASSWORD: the password associated with the Spotify account.



Importing Backups into Spotify again

To achieve this, you just need to open the CSV file of each playlist and extract the values from the “Track URI” column.

This can be done by opening the CSV file with Excel and then navigating to Data => Text to Columns => Next => Delimited (Next) => Comma (Next) => Finish.

spotify csv exporter

Next, simply copy all the Track URIs using Ctrl+C and paste them into a playlist in Spotify Desktop using Ctrl+V.

Automating backups

In Windows, you can automate the script by creating a scheduled task with the Windows Task Scheduler. This can be done by creating a .bat file with the following contents:

@echo off
C:\Python3\python.exe "C:\path\to\"

This will allow the script to run automatically at specified intervals without requiring manual intervention.

In Linux you can use Cron for example.


This tool is licensed under the GPL-3.0 license.