A two-part tool that exports liked songs from Spotify using Go and automatically likes them on YouTube Music using Python, providing a free alternative to paid migration services.
Technologies
Go 1.22+Python 3.10+Spotify APIYouTube Music APIJSONOAuth 2.0ytmusicapiHTTP Clients
Terminal Preview
spotify-to-ytmusic β Migration Tool
$ go run export.go
π΅ Spotify to YouTube Music Migration Tool
ββββββββββββββββββββββββββββββββββββββββ
[1/2] Exporting from Spotify...
β Authenticated with Spotify API
β Fetching liked songs...
β Page 1/8 β 50 songs retrieved
β Page 2/8 β 50 songs retrieved
...
β Page 8/8 β 23 songs retrieved
β Exported 373 songs β liked_songs.json
$ python import.py
[2/2] Importing to YouTube Music...
β Authenticated with YouTube Music
β Processing 373 songs...
[ββββββββββββββββββββββββββ] 289/373
β Liked: "Bohemian Rhapsody" β Queen
β Liked: "Blinding Lights" β The Weeknd
β Skipped: "Local File Track" β not found
β Liked: "Starboy" β The Weeknd
Summary: 361 liked Β· 12 skipped Β· 0 errors
Overview
Overview
This project provides a free, open-source alternative to paid music migration services by combining the strengths of Go and Python.
The Go exporter authenticates with Spotifyβs OAuth 2.0 API, retrieves all liked songs with pagination handling, and saves them as a structured JSON file.
The Python importer reads the exported JSON, searches YouTube Music for each track, and automatically likes matching songs using the ytmusicapi library.
Features
Features
Export (Go)
- Spotify OAuth 2.0 authentication flow
- Automatic pagination for large libraries
- JSON export with artist and track metadata
- Rate limiting and error handling
Import (Python)
- YouTube Music authentication via ytmusicapi
- Fuzzy search matching for track discovery
- Automatic like/save functionality
- Progress tracking with skip detection