# Facebook Search Scraper - Posts, Pages & People (`eiv/facebook-search-scraper`) Actor

Search Facebook without logging in: posts, Pages, people, places and videos by keyword, hashtag or search link. Posts with text, author, date, reactions by type, comments, shares, photos and group. Date ranges search month by month for far more posts. Pay per result.

- **URL**: https://apify.com/eiv/facebook-search-scraper.md
- **Developed by:** [Eimantas V](https://apify.com/eiv) (community)
- **Features:** Limited permissions
- **Stats:** 7 total users, 4 monthly users, 33.3% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 search results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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 Search Scraper** searches Facebook the way its own search box does and returns every result as a row: **public posts, Pages, people, places and videos** for any keyword, hashtag or Facebook search link. Posts come with full text, author, date, reactions by type, comments, shares, photos and the group they were posted in. No login, no cookies, no API key, no browser, from **$2.00 per 1,000 results**.

```
search  date        author                 reactions  comments  shares  group                               text
coffee  2026-10-31  Rose Thompson                228        22      41  Nescafe coffee lovers and recipes   Chocolate caramel macchiato on the menu for this...
coffee  2026-10-30  Rachel Bryant                520       107      75  Nescafe coffee lovers and recipes   Yalllll this is the recipe that keeps me from the...
coffee  2026-08-06  For Coffee's Sake            165        40      77  -                                   Some people say mornings begin with the sun...
coffee  2026-10-31  Cozy Coffee Cravings         188         4      27  -                                   Mornings aren't complete without...
```

**Benchmark on Apify: 90 posts for three searches from 9 search pages in 11 seconds, at 512 MB, with no residential proxy.**

### What does Facebook Search Scraper do?

It runs Facebook searches without an account and saves what Facebook shows a logged-out visitor: the Posts, Pages, People, Places or Videos tab of a search. Give it search terms, hashtags or links to Facebook searches; it pages through the results and returns one clean row per post, Page, person or video.

- **Five kinds of search.** Posts (text, author, date, reactions, comments, shares, media, group), Pages and Places (name, link, picture, verified badge, intro), People (name, link, picture, "Lives in ..." line) and Videos (title, views, length, date, creator).
- **Top or recent posts, and date ranges.** Pick Facebook's top posts or the most recent ones, and limit posts to a date range. A date range is searched month by month through Facebook's own "Date posted" filter, so one keyword returns far more posts than a single search.
- **Paste what you have.** Words (`coffee shop`), hashtags (`#icedcoffee`), Facebook search links with their filters (`facebook.com/search/posts/?q=coffee&filters=...`) and hashtag links (`facebook.com/hashtag/coffee`).
- **Only pay for results.** Duplicates, posts outside your date range and searches that fail are never charged.
- **Built for automation.** Run it on a schedule, call it from the API, or connect it to Make, Zapier, n8n, Google Sheets or an AI agent through Apify's MCP server.

### Why it is fast and cheap

It calls the same search endpoint Facebook's website uses, as a logged-out visitor, over plain HTTP: no browser, no login, no cookies. Each request returns 10-18 results, and only the part of each answer that holds the results is read. Requests go through Apify's datacenter proxy, which is included in every Apify plan, so there is no residential proxy cost to pass on.

### What data can you extract from Facebook search?

**Posts** (`recordType: "post"`)

| Field | Example | What it is |
|---|---|---|
| `text` | `Chocolate caramel macchiato on the menu...` | The full text of the post |
| `date` | `2026-10-31T13:21:37.000Z` | When it was posted (ISO 8601 UTC) |
| `authorName`, `authorId`, `authorUrl` | `Rose Thompson`, `100088662798903` | The Page or person who posted it |
| `groupName`, `groupId`, `groupUrl` | `Nescafe coffee lovers and recipes` | The public group it was posted in |
| `reactionCount`, `reactions` | `152`, `{ "like": 128, "love": 24, ... }` | All reactions, and each type separately |
| `commentCount`, `shareCount` | `22`, `41` | Comments and shares |
| `viewCount` | `2428` | Views of video posts and reels |
| `mediaType` | `album` | text, photo, album, video, reel, link, shared_post... |
| `imageUrls`, `imageDescriptions` | `["https://scontent..."]` | Photos and Facebook's description of each |
| `videoUrl`, `videoThumbnailUrl`, `videoDurationSecs` | | Video posts |
| `linkUrl`, `linkTitle`, `linkDomain` | | The web page a post shares |
| `sharedPostUrl`, `sharedPostText` | | The post a share reshares |
| `hashtags`, `mentions`, `links` | `["icedcoffee"]` | Hashtags, tagged names and links in the text |
| `url`, `postId`, `feedbackId` | `https://www.facebook.com/groups/.../posts/...` | The post's link and ids |

**Pages, places and people** (`recordType: "page"` or `"person"`)

| Field | Example | What it is |
|---|---|---|
| `name` | `7 Brew Coffee` | The name Facebook shows |
| `url`, `username`, `profileId` | `https://www.facebook.com/7brewcoffee` | Link, username and id |
| `isVerified` | `true` | Facebook's verified badge |
| `description` | `We Cultivate Kindness one cup at a time` | A Page's intro, or "Lives in ..." for people |
| `pictureUrl` | `https://scontent...` | Profile picture |

**Videos** (`recordType: "video"`): `title`, `url`, `date`, `viewCount`, `durationSecs`, `thumbnailUrl`, `authorName`, `authorUrl`. Some video results are full posts and come as post rows.

Every row also has `query` (what was searched), `searchType`, `position` (rank in Facebook's results), `input` (your line, unchanged) and `scrapedAt`.

### How to scrape Facebook search results

1. Click **Try for free** and enter your words, hashtags or Facebook search links in **Search terms**, one per line.
2. Choose **Search for**: Posts, Pages, People, Places or Videos. For posts, optionally choose **Recent posts** or a date range.
3. Set **Max results per search** and **Max results in total**. You pay per result, so this is also your cost cap.
4. Click **Start**. A search of 50 posts takes about 15-20 seconds. Download the results as JSON, CSV, Excel or HTML from the **Output** tab.

### How much does it cost to scrape Facebook search?

You pay per result returned, and the price drops on higher Apify plans:

| Apify plan | Per 1,000 results |
|---|---|
| Free | $3.00 |
| Starter | $2.50 |
| Scale | $2.20 |
| Business | $2.00 |

- 50 posts for each of 10 keywords (500 results) costs **$1.25** on the Starter plan.
- 1,000 Pages for a list of local searches costs **$2.00** on the Business plan.
- A run also costs **$0.00005** to start. A search that fails, or finds nothing, costs nothing more.
- The Free plan's $5 monthly credit covers about **1,600 results**.

### Input

```json
{
    "searchQueries": ["coffee", "#icedcoffee", "https://www.facebook.com/search/pages/?q=coffee%20roasters"],
    "searchType": "posts",
    "sortBy": "top",
    "postsNewerThan": "3 months",
    "maxResultsPerQuery": 100,
    "maxItems": 1000
}
```

| Field | Default | Notes |
|---|---|---|
| Search terms | `coffee` (example) | Words, hashtags, Facebook search or hashtag links, one per line |
| Search for | Posts | Posts, Pages, People, Places or Videos. A search link uses its own tab |
| Posts: order | Top | Top posts, or Recent posts (newest first, last few days) |
| Posts: posted after / before | empty | A date (2025-01-31) or a period (7 days, 3 months). Searched month by month |
| Location | empty | Added to every term ("coffee" + "London"). Best for Pages, Places and People |
| Max results per search | 50 | Each search stops here |
| Max results in total | 1,000 | The whole run stops here: your cost cap |
| Proxy | Apify datacenter | Included in every plan. See "Tips and limits" |

Inputs written for apify/facebook-search-scraper (`categories`, `locations`, `searchType`, `resultsLimit`) and scraper_one/facebook-posts-search (`query`, `resultsCount`, `searchType: latest`, `startDate`, `endDate`) work here unchanged.

### Output

Each result is one row. The **Posts**, **Pages, places & people** and **Videos** views show the key columns of each; every export includes all fields.

```json
{
    "recordType": "post",
    "query": "coffee",
    "searchType": "posts",
    "position": 4,
    "postId": "1996225351020098",
    "url": "https://www.facebook.com/groups/1390706024905370/posts/1996225351020098/",
    "date": "2026-10-27T23:08:02.000Z",
    "text": "Was craving something sweet, so I whipped up a little iced decaf latte...",
    "authorName": "Taylor Quon",
    "authorId": "100051328328189",
    "authorUrl": "https://www.facebook.com/taylor.quon.7",
    "groupName": "Nescafe coffee lovers and recipes",
    "groupUrl": "https://www.facebook.com/groups/1390706024905370",
    "reactionCount": 152,
    "reactions": { "like": 128, "love": 24, "care": 0, "haha": 0, "wow": 0, "sad": 0, "angry": 0 },
    "commentCount": 7,
    "shareCount": 14,
    "mediaType": "album",
    "imageUrls": ["https://scontent.xx.fbcdn.net/v/t39.30808-6/..."],
    "hashtags": ["nescafe", "coffeeathome", "homecafe", "icedlatte", "coffeerecipes"],
    "input": "coffee",
    "scrapedAt": "2026-11-03T19:40:52.432Z"
}
```

```json
{
    "recordType": "page",
    "query": "coffee",
    "searchType": "pages",
    "position": 3,
    "profileId": "100064910490989",
    "name": "7 Brew Coffee",
    "url": "https://www.facebook.com/7brewcoffee",
    "username": "7brewcoffee",
    "isVerified": true,
    "description": "We Cultivate Kindness™ one cup at a time 🥤 Download the 7 Brew App now!",
    "pictureUrl": "https://scontent.xx.fbcdn.net/v/t39.30808-1/..."
}
```

A search that cannot be done becomes a row with `"recordType": "error"` and an `errorCode`, and is never charged:

| `errorCode` | Meaning |
|---|---|
| `RATE_LIMITED` | Facebook refused the search from every address the run had; run it again later |
| `PARSE_FAILED` / `FACEBOOK_ERROR` | Facebook changed its search; please report it on the Issues tab |
| `TIMEOUT` | The run timed out before this search; raise the run timeout |

### Tips and limits

- **Facebook limits searches per IP address.** A logged-out visitor gets about 15-20 searches from one IP address before Facebook pauses it for an hour or more; one search page holds 10-18 results. The Actor spreads searches over your plan's Apify datacenter IPs (Free 5, Starter 30, Scale 200, Business 500), so a Free-plan account gets roughly 1,000-1,500 results before it has to wait, and paid plans go much further. Results already collected are kept; searches Facebook refused are listed as uncharged error rows to run again later. When every address is paused the run stops, keeps what it found and charges nothing for the rest.
- **Want more posts per keyword?** Facebook shows a logged-out visitor about 60-90 top posts per search. Set a date range: each month is searched separately and returns its own posts.
- **Recent posts** cover only the last few days; use a date range for older posts.
- **Not available without logging in:** group search, comments under posts (use [Facebook Comments Scraper](https://apify.com/eiv/facebook-comments-scraper) with the post links), a Page's category, followers and contact details (use [Facebook Pages Scraper](https://apify.com/eiv/facebook-pages-scraper) with the Page links).
- **Location** is added to the search text, as you would type it into Facebook; Facebook's own location filter needs a login.
- **Hit your spending limit?** The run stops cleanly at your maximum cost per run and keeps everything it collected. Raise the limit in the run options to get more.

### FAQ

#### Is it legal to scrape Facebook search results?

This Actor collects only data that Facebook shows publicly to visitors who are not logged in. Results can still contain personal data, which laws such as the GDPR protect. Scrape personal data only for a legitimate purpose, and ask a lawyer if you are unsure. Facebook is a trademark of Meta Platforms; this Actor is not affiliated with or endorsed by Meta.

#### Do I need a Facebook account or cookies?

No. Nothing is logged in, and no cookies or tokens of yours are needed or used.

#### Can I use it through the API or with Make, Zapier and n8n?

Yes. Every run can be started through the [Apify API](https://docs.apify.com/api/v2) and returns the dataset as JSON, CSV or Excel. Schedules, webhooks and integrations for Make, Zapier, n8n and Google Sheets are on the **Integrations** tab.

#### Can AI agents use it?

Yes. Agents connected to [Apify's MCP server](https://mcp.apify.com) can find and run this Actor as a tool, with the same per-result pricing.

#### Why did I get fewer results than I asked for?

Facebook shows a limited number of results per search to logged-out visitors, the run may have reached your maximum cost per run or its timeout, or Facebook paused the run's IP addresses. The log says which, and nothing collected before that is lost.

### Related scrapers

- [Facebook Comments Scraper](https://apify.com/eiv/facebook-comments-scraper): every comment and reply under the posts you found.
- [Facebook Pages Scraper](https://apify.com/eiv/facebook-pages-scraper): emails, phones, followers and ratings of the Pages you found.
- [Facebook Posts Scraper](https://apify.com/eiv/facebook-page-monitor): all posts of a Page or profile, with date ranges and monitoring.
- [Facebook Groups Scraper](https://apify.com/eiv/facebook-groups-scraper): the posts of public groups.

### Support

Missing a field, or found a search that does not work? Open an issue on the **Issues** tab with the input you used, and it will be looked at quickly.

# Actor input Schema

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

What to search Facebook for, one per line: words (coffee shop), hashtags (#icedcoffee), brand or person names, or Facebook search links (facebook.com/search/posts/?q=coffee, with their filters) and hashtag links (facebook.com/hashtag/coffee). Each line is one search.

## `searchType` (type: `string`):

Which Facebook search tab to read. Posts: public posts with text, author, date, reactions, comments, shares and media. Pages: business and public Pages. People: public profiles. Places: Pages of local places. Videos: videos and reels with views and duration. A Facebook search link uses its own tab.

## `sortBy` (type: `string`):

Top: Facebook's most relevant posts (the default search, mostly from the last few months). Recent: the newest posts first, from the last few days. Posts searches only.

## `postsNewerThan` (type: `string`):

Only posts published on or after this date (2025-01-31) or within a period (7 days, 3 months). With a date range the search goes month by month through Facebook's own date filter, which finds far more posts than one search. Posts and videos only; leave empty for no limit.

## `postsOlderThan` (type: `string`):

Only posts published on or before this date (2025-12-31) or before a period (1 month). Posts and videos only; leave empty for no limit.

## `location` (type: `string`):

A city, region or country added to every search term (coffee + London searches "coffee London"), the way you would type it into Facebook. Best for Pages, Places and People searches. Leave empty to search everywhere.

## `startUrls` (type: `array`):

Facebook search or hashtag links in the URL-list shape other Actors output, so a previous Actor's results can be fed straight in. Use this or the field above.

## `maxResultsPerQuery` (type: `integer`):

Stop each search after this many results. Facebook shows logged-out visitors about 60-90 top posts per search (more with a date range or Recent), and hundreds of Pages, people, places and videos.

## `maxItems` (type: `integer`):

Stop the run after this many results across all searches. You pay per result, so this is also your cost cap for the run.

## `proxyConfiguration` (type: `object`):

Searches always go through Apify's datacenter proxy, which is included in every plan: Facebook refuses searches from Apify's own servers. Facebook allows about 15-20 searches per IP address before pausing it, so a run's reach grows with your plan's datacenter IPs. A residential proxy chosen here is used only while all datacenter IPs are paused.

## `maxConcurrency` (type: `integer`):

How many searches run at the same time.

## `requestTimeoutSecs` (type: `integer`):

How long to wait for one Facebook answer before trying another address.

## `maxRetries` (type: `integer`):

Retries for failed connections on runs without a proxy (local runs). Refused searches always move to another address.

## Actor input object example

```json
{
  "searchQueries": [
    "coffee"
  ],
  "searchType": "posts",
  "sortBy": "top",
  "maxResultsPerQuery": 50,
  "maxItems": 1000,
  "proxyConfiguration": {
    "useApifyProxy": true
  },
  "maxConcurrency": 3,
  "requestTimeoutSecs": 45,
  "maxRetries": 1
}
```

# Actor output Schema

## `results` (type: `string`):

One row per result (recordType post, page, person or video), plus one uncharged row per search that could not be done (recordType "error").

## `summary` (type: `string`):

Totals for the run: searches, results, failures, search pages, refusals and why the run stopped.

# 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": [
        "coffee"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("eiv/facebook-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": ["coffee"] }

# Run the Actor and wait for it to finish
run = client.actor("eiv/facebook-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": [
    "coffee"
  ]
}' |
apify call eiv/facebook-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,eiv/facebook-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/d0dwiVFORWTX8YnlJ/builds/P5pxZTiHgY5GzQHdf/openapi.json
