spotify-share-liked is a zero-cost local CLI that copies your Spotify "Liked Songs" into a playlist you can share with a link, using the official Spotify Web API.
It is built for people searching for ways to share Spotify liked songs, export Spotify liked songs to a playlist, or turn Spotify liked songs into a shareable playlist without using a hosted third-party service.
Spotify Liked Songs ---> SHARE!
- Zero-cost: Runs entirely on your local machine
- High-privacy: No data sent to external servers, uses official Spotify API only
- OAuth 2.0: Secure authentication with PKCE
- Rate-limit resilient: Automatic retry with exponential backoff
- Batch processing: Efficiently handles large libraries (tested with 469+ tracks)
- Profile-hidden output: Hides the generated playlist from your public profile and search
- Share Spotify liked songs with one link: Copy your library into a standard playlist and send the playlist URL
- Export liked songs without a backend: Everything runs locally on your machine
- Use the official Spotify Web API only: No scraping, no private endpoints, no hosted token storage
- Handle large libraries: Fetches all liked songs with pagination and uploads in 100-track batches
- Node.js LTS (v18 or higher)
- Spotify account
- Spotify Developer App credentials
npm install -g spotify-share-liked# Clone or download the project
cd spotify-share-liked
# Install dependencies
npm install
# Build the project
npm run build- Go to Spotify Developer Dashboard
- Create a new app
- Add
http://127.0.0.1:8888/callbackto the Redirect URIs - Copy your Client ID
Create a .env file in the project root:
SPOTIFY_CLIENT_ID=your_client_id_hereYou can also copy the example file:
cp .env.example .envOptional if you want to use a different callback URL and port:
SPOTIFY_REDIRECT_URI=http://127.0.0.1:8888/callbackIf you set SPOTIFY_REDIRECT_URI, register that exact same URI in the Spotify Developer Dashboard.
The CLI requests these Spotify scopes:
user-library-readplaylist-modify-private
Important: Spotify's official Web API cannot make a playlist link-access private. The CLI can only set public: false, which hides the playlist from your public profile and from Spotify search results.
If you need true link-private access, update the playlist privacy manually in the Spotify desktop client after creation.
npm run devspotify-share-likedspotify-share-liked --name "My Liked Songs"
spotify-share-liked --description "Songs I want to share"
spotify-share-liked --no-open
spotify-share-liked --helpnpm startnpm testnpm link
spotify-share-liked- Authentication: Opens your browser to authenticate with Spotify
- Reading: Fetches all your liked songs using pagination (50 per request)
- Creating: Creates a new playlist called "share liked songs spotify"
- Visibility: Sets
public: falseso the playlist is hidden from profile and search - Uploading: Adds tracks in batches of 100 (Spotify API limit)
- Result: Prints the shareable playlist URL
Yes. This tool copies your Spotify liked songs into a playlist in your own account and prints the playlist URL.
Yes. Use --name "Your Playlist Name" to override the default playlist title.
Run spotify-share-liked --no-open and the CLI will print the Spotify authorization URL for you to open manually.
No. Spotify's official Web API can hide the playlist from your profile and search, but anyone with the direct link can still open it.
Yes. The CLI uses Spotify OAuth and the official Spotify Web API only.
The tool implements automatic retry with exponential backoff:
- Waits for
Retry-Afterheader when receiving HTTP 429 - Falls back to exponential backoff: 1s, 2s, 4s
- Retries up to 3 times before failing
- All credentials stay on your local machine
- Uses official Spotify Web API only
- No external servers or databases
- PKCE flow for secure authentication
- Spotify's Web API cannot create a link-private playlist; anyone with the URL can still access it
MIT