Skip to content

Instantly share code, notes, and snippets.

@eegrok
Created March 20, 2025 21:59
Show Gist options
  • Save eegrok/148e1885d0476808541a4f63c09798a1 to your computer and use it in GitHub Desktop.
Save eegrok/148e1885d0476808541a4f63c09798a1 to your computer and use it in GitHub Desktop.
download facebook album
// go to page with all the thumbnails
// scroll down to make sure all thumbnails have loaded on the page
// find img class -- something like:
// x1g5rohu x5y21rd xlxv11r xh9vej3
// replace that in code below
let urls = []
thumbs = document.getElementsByClassName('x1g5rohu x5y21rd xlxv11r xh9vej3');
for (var i = 0; i < thumbs.length; i++) { urls.push(thumbs[i].src); }
console.log(urls);
// then use the urls to create bash script with wget to download them all
// each line something like
// wget -O <filename> <url>
// or can use wget -i <filename> if you are happy with the facebook url names
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment