SpotifyToMP3Download is a Python WebApp that allows users to convert songs from a Spotify playlist into MP3 format by downloading them from YouTube.
Click the image above to watch the video.
Ensure you have Python 3.x installed on your system. You can download Python from python.org.
# Clone the repository
git clone https://github.com/andreaonorato/SpotifyToMP3Download.git
# Navigate to the project directory
cd SpotifyToMP3Download
# Install the required libraries
pip install -r requirements.txt
- Go to the Google Cloud Console.
- Create a new project or select an existing project.
- Navigate to APIs & Services > Credentials.
- Click on Create Credentials > API key.
- Copy the generated API key and replace
YOUR_YOUTUBE_API_KEY
in theapp.py
file.
- Go to the Spotify Developer Dashboard.
- Log in with your Spotify account or create a new one if needed.
- Create a new application and obtain your Client ID and Client Secret.
- Update
app.py
with your Spotify Client ID and Client Secret.
-
Download ffmpeg:
- Go to the ffmpeg download page.
- Download the latest Windows build, either 32-bit or 64-bit, depending on your system architecture.
-
Extract the ffmpeg archive:
- Extract the downloaded zip file to a folder on your computer. For example,
C:\ffmpeg
.
- Extract the downloaded zip file to a folder on your computer. For example,
-
Add ffmpeg to PATH:
- Open File Explorer and right-click on "This PC" or "Computer".
- Select "Properties" -> "Advanced system settings" -> "Environment Variables".
- In the "System Variables" section, find the "Path" variable and click "Edit".
- Click "New" and add the path to the folder containing
ffmpeg.exe
(e.g.,C:\ffmpeg
). - Click "OK" to save the changes.
-
Verify ffmpeg Installation:
- Open a new command prompt window.
- Type
ffmpeg -version
and press Enter. - You should see the version information for ffmpeg if it's installed correctly.
-
Usage in SpotifyToMP3Download:
- Assign the location of ffmpeg to the variable ffmpeg_path in app.py