I want a data set with the names of all Facebook users from a particular region. Is there a simple way to automatically extract this information?

1 Answer 1


The Facebook Graph-API contains some functionality that you can piece together to do what you asked.

Step 1: Use the User-Friends endpoint to get a list of user-ids. You can use your own user-id as a starting point.

Step 2: Use the User endpoint to get the following information of public profiles:

Provides access to a subset of items that are part of a person's public profile. A person's public profile refers to the following properties on the user object by default:

id, name, first_name, last_name,link,gender,locale,timezone,updated_time,verified

Step 3: Use the user-ids that are in your target region to make additional requests for their friend's lists (step 1), which you can use to get more IDs, more locales, and on and on...

  • Thanks for your answer. I have very limited programming experience. Which programming language should I learn to automate data extraction using Graph API?
    – Green Noob
    Feb 9, 2015 at 9:31
  • 2
    I prefer python, and can recommend the codecademy.com/tracks/python program to get started
    – philshem
    Feb 9, 2015 at 10:15
  • Will I be able to extract data using Graph API once I finish the Codeacademy course?
    – Green Noob
    Feb 10, 2015 at 9:04
  • 1
    apparently you'll need a bit of reading/learning on how to do web API requests and parsing responce or acting on error in request. Part of it is course material referred above, part of it you can read from Facebook developer site. And if there is still gap you can't cover by binding those above - ask here. Don't be afraid, normally it works on very simple level.
    – silpol
    Feb 10, 2015 at 19:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.