Factsheet
Videos
As Google just doesn't seem to care I wrote this little script to export my Google Podcasts listening history: https://gist.github.com/tadwohlrapp/73864c03734a14a9d27cc15e4fa142ba
You can run it in the browser console or as a bookmarklet using a bookmarklet generator like https://caiorss.github.io/bookmarklet-maker/
Per @romanzdk's SO answer to "How can Google Podcasts data be exported/accessed?", you can get the information using Google Takeout:
The only way to download playback history from Google Podcasts I found is to use Google Takeout (this link can be found in the "More options" section of the My Activity — Podcasts page, where you can also see your subscriptions).
If you click the "All activity data included" button, you'll be able to specify which Google app you want to export data form. Click the "Deselect all" option to remove all apps, then check only the Podcasts entry.
You can also select the "Multiple formats" button to pick what format you want for your data export: HTML or JSON files (the default is HTML). The information in the files includes the activity type (playbacks, searches, etc.) and the corresponding date.
Hey everyone.
I'm writing this as an individual wonk listener, not as a mod.
Google Podcasts will be shut down in a week (April 2, 2024). One thing that's been really frustrating about the process is that there's no way to export your listening history. For a long running podcast like Knowledge Fight, that's devastating.
I wrote this script that I used to download my own listening history. Doing something useful with this history (e.g. uploading it) is another problem, but at least I have something I can refer to later.
I'm sharing what I've written in the hopes it can be useful to other people left in the lurch by this shutdown.
Don't run random un-trusted code on your computer. I'm trying to make this as simple to read and open-source as possible so others can inspect what I'm doing. Anyone is free to reuse the following code under the MIT Licence.
// Get all the elements corresponding to the episodes.
var episodes = Array.from(document.getElementsByClassName('oD3fme'));
// For each episode, grab the title, and the little button to play the episode.
// Extract the text (e.g. "Completed", "3 minutes left", "1 hour 40 min")
const episodes_data = episodes.map((episode) => ({
'name': episode.getElementsByClassName('e3ZUqe')[0].textContent,
'playchip': episode.getElementsByClassName('J0Qtec')[0].textContent
}));
// This creates a link element that, when "clicked" will download the data above as a file.
// Then, it "clicks" that element, triggering the download.
// Then, it cleans up the link.
const json_content = JSON.stringify(episodes_data, null, 2);
const blob = new Blob([json_content], { type: 'application/json' });
const url = URL.createObjectURL(blob);
const a = document.createElement('a');
a.href = url;
a.download = 'kf_episodes_listen_history.json';
document.body.appendChild(a);
a.click();
document.body.removeChild(a);
URL.revokeObjectURL(url);Here are instructions for how to use this:
-
I'm using Chrome v123. Other browsers and versions should work fine, but YMMV.
-
Visit the Google Podcasts Web page for Knowledge Fight, while logged into the right Google account. Confirm you can see the listening history in the play chips -- this is what the script will scrape.
-
Run the script. NEVER RUN CODE YOU DON'T UNDERSTAND. You have two options:
-
Open the developer console and paste in the code.
-
Make the code into a bookmarklet, and click that bookmarklet while viewing the page.
-
-
You should see a file
kf_episodes_listen_history.jsonbe downloaded. This file contains a human readable listing of the episode titles and what text was next to the play button, which is enough to know which episodes are complete, which are in progress, and which are untouched.
I hope this can be helpful to others. One final caveat -- the page is obfuscated, and it's possible that the script could break if the obfuscation changes. I don't think that's likely, and I've never seen the class names change in practice, but if it downloads an empty file, that's probably why.
If you are undecided or unsure which app to pick before Google Podcasts is compromised to a permanent end, I've put my r/podcasts mod hat on and have selected a couple of threads from the last couple of months:
https://www.reddit.com/r/podcasts/comments/18zlm2n/goodbye_google_podcasts_hello/
https://www.reddit.com/r/podcasts/comments/1azqdsh/i_gave_youtube_music_a_shot_its_garbage/
https://www.reddit.com/r/podcasts/comments/16sqkmg/google_podcasts_is_shutting_down_in_2024/
More here: https://www.reddit.com/r/podcasts/search?q=google&restrict_sr=on&include_over_18=on&sort=relevance&t=all
Really helpful thanks.
I want to track my podcast listening history.
I currently use Google Podcasts, but it doesn't provide an easy way to export my subscriptions (OPML) or my listening history. I have built a proof of concept to export an OPML file of my subscriptions as well as a list of podcasts I started/finished listening to (with progress %), but I can't find any date or timestamp that says when I listened to a specific podcast.
I'm currently looking to migrate to a more fully-featured app/platform that works on Android (and preferably cross-platform). Do you have any recommendations? As I said earlier, I'm especially interested in precisely tracking my listening history (manual file export or API).