{"id":34032070,"url":"https://github.com/abhishekmj303/ytm2spt","last_synced_at":"2026-04-07T17:31:42.446Z","repository":{"id":183034416,"uuid":"669503749","full_name":"abhishekmj303/ytm2spt","owner":"abhishekmj303","description":"Transfer Playlists from YouTube Music to Spotify","archived":false,"fork":false,"pushed_at":"2025-05-08T20:11:50.000Z","size":396,"stargazers_count":369,"open_issues_count":17,"forks_count":21,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-11-29T05:32:19.346Z","etag":null,"topics":["hacktoberfest","playlist-converter","playlists","spotify","spotipy","thefuzz","transfer-playlists","youtube-music","ytmusicapi"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/ytm2spt","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abhishekmj303.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-07-22T13:46:32.000Z","updated_at":"2025-11-27T20:38:31.000Z","dependencies_parsed_at":"2024-04-14T22:41:10.824Z","dependency_job_id":null,"html_url":"https://github.com/abhishekmj303/ytm2spt","commit_stats":null,"previous_names":["abhishekmj303/ytm2spt"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/abhishekmj303/ytm2spt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abhishekmj303%2Fytm2spt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abhishekmj303%2Fytm2spt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abhishekmj303%2Fytm2spt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abhishekmj303%2Fytm2spt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abhishekmj303","download_url":"https://codeload.github.com/abhishekmj303/ytm2spt/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abhishekmj303%2Fytm2spt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31522247,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-07T16:28:08.000Z","status":"ssl_error","status_checked_at":"2026-04-07T16:28:06.951Z","response_time":105,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest","playlist-converter","playlists","spotify","spotipy","thefuzz","transfer-playlists","youtube-music","ytmusicapi"],"created_at":"2025-12-13T18:35:33.272Z","updated_at":"2026-04-07T17:31:42.435Z","avatar_url":"https://github.com/abhishekmj303.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n   YouTube Music To Spotify\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n   \u003ca href=\"https://github.com/abhishekmj303/ytm2spt/stargazers\"\u003e\u003cimg src=\"https://img.shields.io/github/stars/abhishekmj303/ytm2spt?colorA=363a4f\u0026colorB=b7bdf8\u0026style=for-the-badge\"\u003e\u003c/a\u003e\n   \u003ca href=\"https://github.com/abhishekmj303/ytm2spt/releases/latest\"\u003e\u003cimg src=\"https://img.shields.io/github/v/release/abhishekmj303/ytm2spt?colorA=363a4f\u0026colorB=a6da95\u0026style=for-the-badge\"\u003e\u003c/a\u003e\n   \u003ca href=\"https://github.com/abhishekmj303/ytm2spt/releases\"\u003e\u003cimg src=\"https://img.shields.io/github/downloads/abhishekmj303/ytm2spt/total?colorA=363a4f\u0026colorB=f5a97f\u0026style=for-the-badge\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n   An open-source app for effortlessly transferring playlists from YouTube Music to Spotify.\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n   \u003cimg src=\"https://raw.githubusercontent.com/abhishekmj303/ytm2spt/refs/heads/main/media/app_ui.png\"\u003e\n\u003c/p\u003e\n\n\n## Features\n\n- [x] No limit on size of playlist\n- [x] Support public playlists\n- [x] Support private playlists\n- [x] Auto create or update playlist if it already exists\n- [x] Use fuzzy search to find the best match\n- [x] Copy playlist thumbnail from youtube to spotify\n- [ ] Copy playlist description from youtube to spotify\n- [x] Limit number of songs to be imported in the playlist\n- [x] Dry run mode to test without adding to spotify\n\n\n## Setup\n\n### Spotify Developer Account\n\n**Why?**\n\nBy setting up a Developer account and creating your own credentials (like keys), you are ensuring that the app connects to your account in a safe way without sharing your login details with anyone. It gives you full control over what the app can access and helps keep your Spotify account secure.\n\n1. Create a new app: https://developer.spotify.com/dashboard\n2. Set \"Redirect URI\" to `http://127.0.0.1:8888/callback`\n   ![Spotify create new app](https://raw.githubusercontent.com/abhishekmj303/ytm2spt/refs/heads/main/media/spotify_create_app.png)\n3. Copy the \"Client ID\" and \"Client Secret\" to use later\n   ![Spotify settings](https://raw.githubusercontent.com/abhishekmj303/ytm2spt/refs/heads/main/media/spotify_settings.png)\n   ![Spotify credentials](https://raw.githubusercontent.com/abhishekmj303/ytm2spt/refs/heads/main/media/spotify_credentials.png)\n4. Copy the \"User ID\" from your Spotify account: https://www.spotify.com/in-en/account/profile/\n   ![Spotify username](https://raw.githubusercontent.com/abhishekmj303/ytm2spt/refs/heads/main/media/spotify_username.png)\n\n\n## Installation\n\nDownload the latest version from the following links:\n\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003ctd\u003e\u003ca href=\"https://github.com/abhishekmj303/ytm2spt/releases/latest/download/ytm2spt-linux.tar.gz\"\u003e\u003cimg src=\"https://img.shields.io/badge/Linux-363a4f?style=for-the-badge\u0026logo=linux\u0026logoColor=white\" alt=\"Linux\"\u003e\u003c/a\u003e\u003c/td\u003e\n    \u003ctd\u003e\u003ca href=\"https://github.com/abhishekmj303/ytm2spt/releases/latest/download/ytm2spt-windows.zip\"\u003e\u003cimg src=\"https://img.shields.io/badge/Windows-363a4f?style=for-the-badge\u0026logo=windows\u0026logoColor=white\" alt=\"Windows\"\u003e\u003c/a\u003e\u003c/td\u003e\n    \u003ctd\u003e\u003ca href=\"https://github.com/abhishekmj303/ytm2spt/releases/latest/download/ytm2spt-macos.zip\"\u003e\u003cimg src=\"https://img.shields.io/badge/Mac OS-363a4f?style=for-the-badge\u0026logo=apple\u0026logoColor=white\" alt=\"MacOS\"\u003e\u003c/a\u003e\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\n\n\u003e [!NOTE]\u003cbr\u003e\n\u003e **Windows**: Windows Defender may interrupt the app from running. Click on more info and allow the program to run.\n\u003e\n\u003e **Linux**: You need to run the app from terminal, if you want the to know the progress of the transfer.\n\n**Using pip or [pipx](https://github.com/pypa/pipx#install-pipx):**\n\n[![PyPI - Version](https://img.shields.io/pypi/v/ytm2spt?colorA=363a4f\u0026colorB=c6a0f6\u0026style=for-the-badge)](https://pypi.org/project/ytm2spt/)\n[![PyPI - Downloads](https://img.shields.io/pypi/dm/ytm2spt?colorA=363a4f\u0026colorB=f0c6c6\u0026style=for-the-badge)](https://pypi.org/p/ytm2spt/)\n\nIf you have Python installed, you can install the app using [pipx](https://pipx.pypa.io/) (recommended) or pip.\n\n```sh\npipx install ytm2spt\n```\n\nor\n\n```sh\npip install ytm2spt\n```\n\nAfter installation, you can run the app using the command `ytm2spt`.\n\n\u003e [!CAUTION]\u003cbr\u003e\n\u003e While syncing into an existing spotify playlist, first all the songs from Stopify playlist will be deleted and then the all the songs from YouTube Music playlist will be copied.\n\n\n### Spotify Settings\n\nWhen you run the executable, you will be prompted to enter your Spotify credentials.\n\n![Spotify Settings](media/spotify_ui.png)\n\n### Youtube Settings\n\nIf you click on \"Private Playlist\", you will be prompted to enter get your Youtube OAuth credentials if not already set.\n\n![Youtube Settings](media/youtube_ui.png)\n\n\n\u003e [!TIP]\u003cbr\u003e\n\u003e If you find this project useful or interesting, please consider giving it a 🌟star! It helps others discover it too!\n\n---\n\n## GUI\n\nPython3 is required to run the app. You can download it from [python.org](https://www.python.org/downloads/) for Windows.\n\n### Install Dependencies\n```sh\npip install .\n```\n\n### Run the App\n```sh\npython ytm2spt.py\n```\n\n## CLI\n\n### Setting Environment Variables Linux and Mac\n\n1. Rename the file `.env.sample` to `.env`\n2. Edit the file by adding your credentials\n3. Run the following command to set your environment variable: `source .env`\n\n\n### Setting Environment Variables (Windows)\n\n1. Edit `env.bat` file by adding your credentials in these lines\n   ```bat\n   set SPOTIFY_USER_ID=\u003cyour_user_id\u003e\n   set SPOTIFY_CLIENT_ID=\u003cyour_client_id\u003e\n   set SPOTIFY_CLIENT_SECRET=\u003cyour_client_secret\u003e\n   ```\n2. Run the batch file to set your environment variable: \n   ```bat\n   env.bat\n   ```\n\n\u003e[!NOTE]\u003cbr\u003e\n\u003e If the environment variables are not set, you may need to restart your terminal or IDE.\n\n### Install Dependencies\n```sh\npip install -r requirements.txt\n```\n\n### Youtube OAuth (Only for private playlists)\n\nRun the following command to login to your Youtube account and save the credentials to `ytmusicapi-oauth.json`\n```sh\nytmusicapi-oauth\n```\n\n## Usage\n\n```sh\n$ source .env\n$ ytm2spt -h\nusage: ytm2spt [-h] -yt YOUTUBE_URL_OR_ID\n               [-sp SPOTIFY_URL_OR_ID | -spname SPOTIFY_PLAYLIST_NAME]\n               [-ytauth YOUTUBE_OAUTH_JSON]\n               [-n | -d] [-l LIMIT]\n\noptions:\n  -h, --help            show this help message and exit\n  -yt YOUTUBE_URL_OR_ID, --youtube-url-or-id YOUTUBE_URL_OR_ID\n                        Youtube Playlist URL or ID\n  -sp SPOTIFY_URL_OR_ID, --spotify-url-or-id SPOTIFY_URL_OR_ID\n                        Spotify Playlist URL or ID\n  -spname SPOTIFY_PLAYLIST_NAME, --spotify-playlist-name SPOTIFY_PLAYLIST_NAME\n                        Spotify Playlist Name (Default: Youtube Playlist Name)\n  -ytauth YOUTUBE_OAUTH_JSON, --youtube-oauth-json YOUTUBE_OAUTH_JSON\n                        Youtube OAuth JSON filepath (run 'ytmusicapi-oauth')\n  -n, --create-new      Force create a new playlist\n  -d, --dryrun          Do not add to Spotify\n  -l LIMIT, --limit LIMIT\n                        Limit the number of songs to fetch\n```\n\n```sh\n$ ytmusicapi-oauth -h\nusage: ytmusicapi-oauth [-h] [-b] [file]\n\npositional arguments:\n  file                file path to store the json (Default: ytmusic-oauth.json)\n\noptions:\n  -h, --help          show this help message and exit\n  -b, --open-browser  open browser for OAuth login (Default: True)\n```\n\n### Examples\n\nSample Playlist: Pop Certified ([YouTube Music](https://music.youtube.com/playlist?list=RDCLAK5uy_lBNUteBRencHzKelu5iDHwLF6mYqjL-JU) to [Spotify](https://open.spotify.com/playlist/6DyIxXHMwuEMbsfPTIr9C8))\n\n```sh\n# Pass any link containing a youtube playlist ID\n# Sets same name as youtube playlist\n$ python ytm2spt.py -yt \"https://music.youtube.com/playlist?list=RDCLAK5uy_lBNUteBRencHzKelu5iDHwLF6mYqjL-JU\"\n\n# Pass just the youtube playlist ID\n# Set a custom name for the playlist\n$ python ytm2spt.py -yt \"CLAK5uy_lBNUteBRencHzKelu5iDHwLF6mYqjL-JU\" -spname \"Pop Certified\"\n\n# Pass link of a private youtube playlist\n# Provide the path to the oauth.json file\n$ python ytm2spt.py -yt \"https://music.youtube.com/playlist?list=PLz96m0PSfi9p8ABcEcUlSMVmz7sN-IEFu\" -ytauth \"oauth.json\"\n\n# Pass an existing spotify playlist URL or ID\n# Limit the number of songs to fetch\n# Dry run mode\n$ python ytm2spt.py -yt \"CLAK5uy_lBNUteBRencHzKelu5iDHwLF6mYqjL-JU\" -sp \"https://open.spotify.com/playlist/6DyIxXHMwuEMbsfPTIr9C8\" -l 10 -d\n\n# Pass even the URL of video playing from playlist\n# Force create a new playlist\n$ python ytm2spt.py -yt \"https://www.youtube.com/watch?v=RlPNh_PBZb4\u0026list=RDCLAK5uy_lBNUteBRencHzKelu5iDHwLF6mYqjL-JU\" -n\n```\n\n\n## Build an Executable\n\n**Note:** This is only required if you want to build the executable yourself. This is not necessary if you just need to run the app directly using Python.\n\n**Requirements:**\n- C Compiler (gcc, clang)\n- `patchelf` (Linux only)\n- `python3-devel` or similar package in your OS\n\n```sh\npip install -r requirements-dev.txt\nnuitka ytm2spt.py\n```\n\n\n\u003e [!NOTE]\u003cbr\u003e\n\u003e Forked from @edgarh22's [Youtube-to-Spotify-Archiver](https://github.com/edgarh92/Youtube-to-Spotify-Archiver).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabhishekmj303%2Fytm2spt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabhishekmj303%2Fytm2spt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabhishekmj303%2Fytm2spt/lists"}