# Facebook Review Scraper (`scrapyspider/facebook-review-scraper`) Actor

Scrape public reviews from Facebook business pages using Facebook’s internal GraphQL API. Extract reviewer names, review text, dates, and post URLs in structured JSON. No login required.

- **URL**: https://apify.com/scrapyspider/facebook-review-scraper.md
- **Developed by:** [ScrapySpider](https://apify.com/scrapyspider) (community)
- **Categories:** Social media, Lead generation, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

### What does Facebook Review Scraper do?

**Facebook Review Scraper** extracts **public Facebook business page reviews** through Facebook's internal **GraphQL API**. The Actor sends lightweight HTTP POST requests directly to `/api/graphql/`, parses the response, and saves each review as a structured record in your Apify dataset — including the reviewer name, recommendation status, review text, date, and profile link.

Because it works entirely over HTTP (no Playwright, no visible browser, no Facebook login), it is faster and cheaper than browser-based scrapers. You get full API access, scheduling, proxy rotation, dataset exports in multiple formats, and easy integration with spreadsheets, BI tools, CRMs, or AI pipelines on the Apify platform.

Try it live on a public reviews page like [The Copper Kettle](https://www.facebook.com/copperkettleyqr/reviews).

### Why use Facebook Review Scraper?

- **Reputation monitoring** — Track new customer feedback for your own business page automatically.
- **Competitor analysis** — Compare review sentiment and volume across competing businesses.
- **Customer research** — Export review text for NLP, sentiment analysis, or topic clustering.
- **Multi-location reporting** — Collect reviews from franchise or branch pages into one dataset.
- **Lead qualification** — Check what customers praise or complain about before sales outreach.
- **Market intelligence** — Spot recurring service issues, pricing concerns, or brand perception trends.

### How to use Facebook Review Scraper

1. Open the Actor on Apify Console.
2. Go to the **Input** tab.
3. Paste a **Facebook page URL** or a **numeric page ID** — use one, not both.
4. Set `maxReviews` to the number of reviews you need. Leave it at `100` to start.
5. Click **Start**. The Actor scrapes, paginates, and saves results automatically.
6. When the run finishes, open the **Output** tab or **Dataset** to view and download results.

**Supported URL formats for `facebookPageUrl`:**

| Format | Example |
|---|---|
| Reviews tab URL | `https://www.facebook.com/copperkettleyqr/reviews` |
| Standard page URL | `https://www.facebook.com/copperkettleyqr` |
| Numeric page-ID URL | `https://www.facebook.com/100064027242849` |
| profile.php URL | `https://www.facebook.com/profile.php?id=100064027242849` |

### Input

| Field | Type | Required | Description |
|---|---|---|---|
| `facebookPageUrl` | String | No* | Any supported Facebook page URL (see formats above). |
| `pageId` | String | No* | Numeric Facebook page ID, e.g. `100064027242849`. Faster — skips URL resolution. |
| `maxReviews` | Integer | No | Maximum reviews to scrape. Default `100`. Set `0` for unlimited. |
| `docId` | String | No | Advanced: GraphQL document ID override. Change only if Facebook rotates their internal API. |

\* Provide exactly one of `facebookPageUrl` or `pageId`.

#### Example input

```json
{
  "facebookPageUrl": "https://www.facebook.com/copperkettleyqr/reviews",
  "maxReviews": 50
}
````

### Output

Each dataset item is one review. Below is a real example from a live scrape:

```json
{
  "postId": "UzpfSTEwMDAwODg0Mjg0MTAzMDozNDMzNTYyNDMzNjE1MTUxOjM0MzM1NjI0MzM2MTUxNTE=",
  "pageId": "100064027242849",
  "reviewer": "Daniel Masih",
  "reviewerUrl": "https://www.facebook.com/daniel.masih.313",
  "userId": "100008842841030",
  "text": "They offers a cozy atmosphere, friendly service, and a menu of tasty comfort food at reasonable prices. It's a great spot for casual dining.",
  "date": "2024-09-11",
  "postUrl": "https://www.facebook.com/daniel.masih.313/posts/pfbid0bWGvcZQ9v4qNexM8r68BsjKi9dTe2tLFxouJ4E4pfgSQtSW1YgBdcpsBDzCduCi2l",
  "isRecommended": true,
  "scrapedAt": "2026-05-09T11:31:42.508Z"
}
```

You can download the dataset in **JSON, CSV, Excel, XML, RSS**, and other formats from the Apify Console.

### Data table

| Field | Type | Description |
|---|---|---|
| `postId` | String | Base64-encoded internal Facebook Story ID for this review post. |
| `pageId` | String | Numeric ID of the Facebook page that was scraped. |
| `reviewer` | String | Display name of the reviewer. |
| `reviewerUrl` | String | null | Facebook profile URL of the reviewer. `null` for privacy-restricted accounts. |
| `userId` | String | Facebook user ID — numeric (e.g. `100008842841030`) or `pfbid`-format for privacy-restricted profiles. |
| `text` | String | Full review body text as written by the reviewer. |
| `date` | String | Date the review was posted in `YYYY-MM-DD` format. |
| `postUrl` | String | null | Direct URL to this specific review post on Facebook. |
| `isRecommended` | Boolean | null | `true` = recommends the business, `false` = does not recommend, `null` = could not be determined. |
| `scrapedAt` | String | ISO 8601 timestamp of when this record was saved by the Actor. |

### Pricing / Cost estimation

This Actor uses a **lightweight HTTP + GraphQL approach** with no browser. There is no Playwright startup, no page rendering, and no login flow. Compute costs are significantly lower than browser-based scrapers.

Typical runs scraping 100 reviews finish in under 30 seconds. The Apify **free tier** is more than enough for initial testing and small recurring jobs.

### Tips and advanced options

#### Finding the numeric page ID

If URL resolution fails, you can get the numeric page ID from:

- [findmyfbid.com](https://findmyfbid.com) — paste the page URL and it returns the ID.
- The Facebook page source — search for `"pageID"` in the raw HTML.
- Your browser's Network tab — intercept a GraphQL request and look at `variables.id`.

#### What to do if `docId` breaks

Facebook assigns numeric IDs to all their internal GraphQL queries at build time. If the Actor suddenly returns no reviews, the `docId` may have changed. To get the new value:

1. Open Chrome DevTools → **Network** tab on any Facebook reviews page.
2. Filter for `graphql`.
3. Click any POST request and look at the form body for `doc_id=XXXXXXXXX`.
4. Copy that value and paste it into the `docId` input field.

#### Private reviewer profiles

## Some reviewers have privacy-restricted Facebook accounts. For these, `userId` will be in `pfbid`-format (e.g. `pfbid02GUAEzN8WfhZ...`) and `reviewerUrl` will be derived from the post URL slug rather than the profile directly. This is normal Facebook behaviour, not a scraper error.

### Author

**ScrapySpider**

- Website: [ScrapySpider.com](https://ScrapySpider.com)
- Email: <ScrapySpider@protonmail.com>

# Actor input Schema

## `facebookPageUrl` (type: `string`):

Accepts Facebook page URLs in any supported format, including review URLs (https://www.facebook.com/copperkettleyqr/reviews), profile URLs (https://www.facebook.com/profile.php?id=100064027242849), page-ID URLs (https://www.facebook.com/100064027242849), and standard page URLs (https://www.facebook.com/copperkettleyqr).

## `pageId` (type: `string`):

Provide the numeric Facebook page ID directly, for example 100064027242849.

## `maxReviews` (type: `integer`):

Maximum number of reviews to scrape. Set to 0 for unlimited.

## Actor input object example

```json
{
  "facebookPageUrl": "https://www.facebook.com/copperkettleyqr/reviews",
  "maxReviews": 20
}
```

# Actor output Schema

## `reviews` (type: `string`):

Dataset containing all scraped reviews. Each item includes the reviewer name, profile URL, review text, recommendation status (true/false), review date, post URL, and IDs. Download as JSON, CSV, or Excel.

## `debugGraphqlResponse` (type: `string`):

Raw NDJSON response from Facebook's GraphQL API for the first page of reviews. Useful for diagnosing broken doc\_id or schema changes.

## `debugResolverHtml` (type: `string`):

First 15 KB of the Facebook page HTML fetched during slug-to-ID resolution. Useful for diagnosing why a page URL fails to resolve.

# 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 = {
    "facebookPageUrl": "https://www.facebook.com/copperkettleyqr/reviews",
    "maxReviews": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapyspider/facebook-review-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 = {
    "facebookPageUrl": "https://www.facebook.com/copperkettleyqr/reviews",
    "maxReviews": 20,
}

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

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

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

```

## CLI example

```bash
echo '{
  "facebookPageUrl": "https://www.facebook.com/copperkettleyqr/reviews",
  "maxReviews": 20
}' |
apify call scrapyspider/facebook-review-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=scrapyspider/facebook-review-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Facebook Review Scraper",
        "description": "Scrape public reviews from Facebook business pages using Facebook’s internal GraphQL API. Extract reviewer names, review text, dates, and post URLs in structured JSON. No login required.",
        "version": "0.0",
        "x-build-id": "8DjH9jcesmlI5t2Pr"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/scrapyspider~facebook-review-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-scrapyspider-facebook-review-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/scrapyspider~facebook-review-scraper/runs": {
            "post": {
                "operationId": "runs-sync-scrapyspider-facebook-review-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/scrapyspider~facebook-review-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-scrapyspider-facebook-review-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "facebookPageUrl": {
                        "title": "Facebook Page URL",
                        "type": "string",
                        "description": "Accepts Facebook page URLs in any supported format, including review URLs (https://www.facebook.com/copperkettleyqr/reviews), profile URLs (https://www.facebook.com/profile.php?id=100064027242849), page-ID URLs (https://www.facebook.com/100064027242849), and standard page URLs (https://www.facebook.com/copperkettleyqr)."
                    },
                    "pageId": {
                        "title": "Facebook Page ID",
                        "type": "string",
                        "description": "Provide the numeric Facebook page ID directly, for example 100064027242849."
                    },
                    "maxReviews": {
                        "title": "Max Reviews",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Maximum number of reviews to scrape. Set to 0 for unlimited.",
                        "default": 100
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
