Ultimate Facebook Scraper: scrapes almost everything about a Facebook user’s profile
Ultimate Facebook Scraper (UFS)
Tooling that automates your social media interactions to collect posts, photos, videos, friends, followers and much more on Facebook.
Features
A bot which scrapes almost everything about a Facebook user’s profile including
- uploaded photos
- tagged photos
- videos
- friends list and their profile photos (including Followers, Following, Work Friends, College Friends, etc)
- and all public posts/statuses available on the user’s timeline.
The best thing about this scraper is that the data is scraped in an organized format so that it can be used for educational/research purposes by researchers. Moreover, this scraper does not use Facebook’s Graph API so there are no rate-limiting issues as such.
Install
You will need to install the latest version of Google Chrome. Moreover, you need to install selenium module as well using
pip install selenium
Run the code using Python 3. Also, the code is multi-platform and is tested on both Windows and Linux. The tool uses the latest version of Chrome Web Driver. I have placed the webdriver along with the code but if that version doesn’t work then replace the chrome web driver with the latest one.
git clone https://github.com/harismuneer/Ultimate-Facebook-Scraper.git
How to Run
There’s a file named “input.txt”. You can add as many profiles as you want in the following format with each link on a new line:
https://www.facebook.com/andrew.ng.96 https://www.facebook.com/zuck
Make sure the link only contains the username or id number at the end and not any other stuff. Make sure it’s in the format mentioned above.
Note: There are two modes to download Friends Profile Pics and the user’s Photos: Large Size and Small Size. You can change the following variables. By default, they are set to Small-Sized Pics because it’s really quick while Large Size Mode takes time depending on the number of pictures to download
Important Message
This tool is for research purposes only. Hence, the developers of this tool won’t be responsible for any misuse of data collected using this tool. Used by many researchers and open-source intelligence (OSINT) analysts.
Copyright (c) 2018 harismuneer, Hassaan-Elahi
Source: https://github.com/harismuneer/
Suggested reading: Is web scraping legal? The Definitive guide [2020 guide]