# Facebook People Search Scraper (`khadinakbar/facebook-people-search-scraper`) Actor

Search Facebook's anonymous public people directory by name or phrase. Return profile names, IDs, links, photo URLs, source query, rank and capture time. Directory coverage is partial; no login or private-profile access.

- **URL**: https://apify.com/khadinakbar/facebook-people-search-scraper.md
- **Developed by:** [Khadin Akbar](https://apify.com/khadinakbar) (community)
- **Categories:** Social media, Lead generation, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.70 / 1,000 public profile saveds

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### Facebook People Search Scraper

Type a name and get back the public profile cards Facebook shows for it in its open people directory: name, profile link, profile ID and rank. No login, no cookies.

**What to expect, plainly:** Facebook shows only about 12 to 13 public cards per search. This Actor gives you that sample quickly and cheaply. It does not return everyone with that name, it does not read private profiles, and it cannot filter by exact city, job or school. A match is a lead to check by hand, not proof of who someone is.

### What's new (version 0.2)

- Optional **extra words** (for example a city or a job) search each name again as "name + word" and tend to show different people.
- **Profile photo links are now off by default.** Turn on "Include profile photo links" if you need them. Earlier versions always returned the photo link.
- Fields Facebook does not show (extra card line, verified label) are left out instead of saved empty.
- Reads Facebook's newer page layout too, so fewer searches fail.
- Every run ends with one plain sentence saying what happened.

### What you get

| Field | Meaning |
| --- | --- |
| `name`, `profileUrl`, `profileId` | Name on the card, link to the public profile, and its ID |
| `query`, `rank`, `pageNumber` | Which search found it and its position in Facebook's list |
| `profilePictureUrl` | Public photo link. Only when you turn on "Include profile photo links" |
| `context`, `isVerified` | Extra card line and verified label. Only present when Facebook shows them (usually not), never saved empty |
| `sourceUrl`, `scrapedAt`, `isPartialCoverage` | The directory page used, capture time, and a reminder that coverage is partial |

### Who it is for

Researchers, journalists, HR and compliance staff, and anyone who needs a short list of public profile links for a name they already have a lawful reason to check. Example: search "Maria Garcia" and review the links by hand.

### Input

```json
{
  "searchQueries": ["John Smith", "Jane Doe"],
  "extraWords": ["London", "teacher"],
  "maxResults": 40,
  "includePhotos": false
}
```

- `searchQueries`: 1–20 names. Each is one search.
- `extraWords` (optional, up to 5): each name is also searched as "name + word", for example "John Smith London". In our test this showed different people each time. It is a plain text search, not a verified city or job filter. Names plus words cannot exceed 20 searches. People found by more than one search are saved and charged once.
- `maxResults`: 1–500 profiles across the whole run (default 20).
- `includePhotos`: off by default.
- `deduplicate`: on by default; always on when you use extra words.
- `maxPagesPerQuery` (advanced, default 1): Facebook has not offered a usable second page to anonymous visitors in our tests, so raising it rarely adds people.

### Output example

```json
{
  "profileId": "100000000000001",
  "profileUrl": "https://www.facebook.com/people/Example-Person/100000000000001/",
  "name": "Example Person",
  "query": "Example Person",
  "rank": 1,
  "pageNumber": 1,
  "sourceUrl": "https://www.facebook.com/public/Example-Person?locale=en_US",
  "scrapedAt": "2026-11-23T00:00:00.000Z",
  "isPartialCoverage": true
}
```

Download as JSON, CSV or Excel. The `OUTPUT` record in the run's storage has a one-sentence result, for example "Done. Saved 13 public profile cards from 1 search(es)…" or "Stopped early at your result limit…". A search with no matches says "Facebook found no public profiles" and charges nothing for profiles. If Facebook blocks or changes the page, the run says so instead of pretending it was empty.

### Pricing

Pay per event: $0.003 to start a run plus $0.001 per saved profile, plus Apify platform usage, which is small (about $0.001 for a 13-profile run). Example: 13 profiles cost $0.016 plus usage. Empty and failed runs cost only the start fee and usage. Set a spending limit on the run in Apify if you want a hard cap. Check the Pricing tab for current prices and any plan discounts.

### API example

```bash
curl --request POST \
  'https://api.apify.com/v2/acts/khadinakbar~facebook-people-search-scraper/runs?memory=256&timeout=120&maxTotalChargeUsd=0.05' \
  --header "Authorization: Bearer $APIFY_TOKEN" \
  --header 'Content-Type: application/json' \
  --data '{"searchQueries":["John Smith"],"maxResults":5}'
```

The API returns run and storage IDs. Wait for the run to end, then read the dataset and `OUTPUT`.

AI agent prompt: "Search khadinakbar/facebook-people-search-scraper for these names with maxResults 20. Read OUTPUT and the dataset. Report that coverage is partial and show the links for human review."

### Privacy and responsible use

- Only public directory cards that Facebook shows to visitors who are not logged in. No login, no cookies, no private profiles, no contact details, no watching a person over time.
- Results are names and links of real people. Use them only for a lawful, specific purpose where you have the right to do so, and follow the privacy laws that apply to you. Do not use them to harass, stalk, profile sensitive traits, or make automated decisions about people.
- A name match is not proof of identity, job or location. Always verify by hand.
- Queries go to Facebook. Apify stores your input and results under your account's retention settings; delete the run storage when you are done. Nothing is sent anywhere else, and no photos are downloaded.
- Public visibility does not by itself give you permission to collect or reuse personal data. You are responsible for your use.
- Facebook can change its pages at any time. This Actor is independent and not affiliated with or endorsed by Meta.

### If something looks wrong

Fewer than about 12 cards for a common name, or an empty result for a rare one, is normal. A message saying Facebook blocked or changed the page is a real source problem: try again later and report it in the Issues tab (do not include passwords or personal data).

# Actor input Schema

## `searchQueries` (type: `array`):

Enter 1–20 names, one per line. Example: John Smith. Each name is looked up in Facebook's public directory, which shows only about 12 to 13 public profile cards per search. It is not the logged-in Facebook people search.

## `extraWords` (type: `array`):

Optional, up to 5 short words such as a city or a job (London, teacher). Each name is also searched as 'name + word', which tends to show different people. These are plain text searches, not exact city, job or school filters, and a match is not proof. Names plus words may not exceed 20 searches in total. People found twice are saved and charged once.

## `maxResults` (type: `integer`):

Most profiles to save across all searches (1–500). A limit, not a promised number: Facebook shows only about 12 to 13 per search.

## `includePhotos` (type: `boolean`):

Off by default. Turn on only if you need the public photo link to tell similar names apart. Photos are not downloaded.

## `deduplicate` (type: `boolean`):

On by default. Each profile is saved and charged once even if several searches find it. Turning it off keeps one row per profile per search. Always on when you use extra words.

## `query` (type: `string`):

Optional: a single name instead of the list above. The list takes precedence if both are given. Plain text, not a URL.

## `maxPagesPerQuery` (type: `integer`):

Default 1. Facebook's public directory has not offered a usable second page in our tests, so raising this rarely adds people (1–5). It also stops at your result limit, spending limit or run time.

## Actor input object example

```json
{
  "searchQueries": [
    "John Smith"
  ],
  "maxResults": 20,
  "includePhotos": false,
  "deduplicate": true,
  "query": "",
  "maxPagesPerQuery": 1
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

## `output` (type: `string`):

No description

## `runSummary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchQueries": [
        "John Smith"
    ],
    "query": ""
};

// Run the Actor and wait for it to finish
const run = await client.actor("khadinakbar/facebook-people-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "searchQueries": ["John Smith"],
    "query": "",
}

# Run the Actor and wait for it to finish
run = client.actor("khadinakbar/facebook-people-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchQueries": [
    "John Smith"
  ],
  "query": ""
}' |
apify call khadinakbar/facebook-people-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,khadinakbar/facebook-people-search-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/3YzxEnnsCcUBfF3pC/builds/IMp5TDkU3P336LiWa/openapi.json
