This script allows you to submit your YouTube Music watch history to Listenbrainz.
- Python 3.x installed on your computer.
- An active Listenbrainz account.
- Your YouTube Music watch history file from Google Takeout.
- Visit Google Takeout.
- From the list of data to include, deselect all except for YouTube and YouTube Music.
- Within the YouTube and YouTube Music section, select only history and then watch history.
- Click Next step and follow the prompts to download your watch history, which will be provided as a
watch-history.jsonfile.
- Download
YTMusic2listenbrainz.pyscript from this repository. - Place your
watch-history.jsonfile in the same directory as theYTMusic2listenbrainz.pyscript. - Enter your
listenbrainz_tokeninYTMusic2listenbrainz.py.
Open a terminal or command prompt and navigate to the directory containing the script and your watch history file. Run the script with the following command:
python3 YTMusic2listenbrainz.pyAfter running the script, log in to your Listenbrainz account to verify that your watch history has been submitted successfully.
Hello, I stumbled upon this post and noticed that it worked great, albeit for the little data that the watch-history.json made. I downloaded the watch-history.html instead, which contains the entire watch history. I created a script and thought you all would like to know. I took heavy inspo from you, thanks a ton for your hard inital work @fuddl!
@brend-an @elliaster
My script can be found here: https://github.com/BlakeAlvarez/YTMusic-ListenBrainz-Importer.git as
ytmusic-listenbrainz-importer.pyPlease feel free to critique or comment on any changes needed to be done, I would love feedback or tips!