Have you ever wanted to see your full YouTube watching history, but found out that YouTube doesn't allow you to do that? Scrolling down the history to get records more than few days back would be really a awful experience. Fortunately, here comes the YouTube History Downloader, small tool written in Scala, that allows you to fetch your entire history within few minutes!
Please note this tool is still in development, so it might not work 100% and some functionality and documentation might be missing.
- multiplatform (running on Java, supports macOS, Windows, GNU/Linux)
- downloads history into CSV file
- generates fancy HTML report from the CSV file
- proper GUI to make it more friendly for people without command-line knowledge
- refactor the main logic as a proper library so you can use it in your code
- improve the HTML report (more options, better performance)
In order that YouTube History Downloader can fetch your YouTube history, you must copy the YouTube-related cookies from your web browser into the cookies.txt
file placed inside the project main directory. Here are steps how to do it:
- Open YouTube in your web browser.
- Find one of the request in Developer tools and copy the Cookie HTTP request header content.
- Copy that string into the
cookies.txt
file. The content should look like this:VISITOR_INFO1_LIVE=someTokenHere; PREF=f1=someTokenHere; CONSENT=YES+CZ.cs+20151207-13-0; YSC=someTokenHere; GPS=1; SID=someTokenHere; HSID=someTokenHere; SSID=someTokenHere; APISID=T-someTokenHere/someTokenHere; SAPISID=someTokenHere; LOGIN_INFO=someTokenHere==
- Clone this repository:
git clone https://github.com/vaclavsvejcar/youtube-history-downloader.git
- Enter SBT console:
$ sbt
- Fetch the history using the
> run fetch
command. This will save the history data into thehistory.csv
file. Now you can open this file in your favorite CSV editor, or generate the HTML report. - You can generate the HTML report using
> run report
command. This will generate HTML filereport.html
.Please note that for large history files, opening the report in web browser may take some time.
You can get the list of bellow option either by running the java -jar yhd.jar --help
(binary) or run --help
(SBT):
Usage: yhd [fetch|report] [options]
--help Prints this help text
Command: fetch [options]
Fetches the youtube history into the output CSV file
-c, --cookies <file> file containing the copied YouTube cookies (default: cookies.txt)
-o, --output <file> Output CSV file with YouTube history (default: history.csv)
Command: report [options]
Generates pretty HTML report from the previously fetched CSV file
-o, --output <file> Output HTML file with the generated report (default: report.html)
coming soon!
Are you missing some cool feature or have you found a bug? Feel free to open new issue, or create a merge request :-)