# Facebook Photos Scraper (`socialdataapi/facebook-photos-scraper`) Actor

Facebook Photos Scraper — Extract Facebook photo data including image URLs, captions, post dates, reactions, comments, shares, page or profile details, and source URLs. Useful for content research, competitor analysis, social media monitoring, and audience insights.

- **URL**: https://apify.com/socialdataapi/facebook-photos-scraper.md
- **Developed by:** [Social Data API](https://apify.com/socialdataapi) (community)
- **Stats:** 4 total users, 3 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 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/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 Photos Scraper — Image Links, Captions, Alt Text, Reactions

Facebook Photos Scraper extracts public photos from Facebook profiles and pages. For every photo it returns the full-size image link, the photo link and photo ID, the post caption, Facebook's own alt text, the posting time, the image size, the owner and the reaction count. Every response is structured JSON — ready to pass directly to an LLM, index into a vector store, or feed a computer-vision dataset pipeline. **No Facebook account or cookies needed.** Start with one page, then add every profile and brand you follow.

![Facebook Photos Scraper output: image links, captions, alt text and reactions as JSON](https://api.apify.com/v2/key-value-stores/WYkyEfqs10huyXYxr/records/g-fb-photos-hero.webp)

***

### What data can I extract with Facebook Photos Scraper?

Using this Facebook Photos API, you will be able to extract the following Facebook photo data:

| 🖼️ Full-size image link | 🔗 Photo link | 🆔 Photo ID | 📝 Post caption |
|---|---|---|---|
| 🦯 Alt text (Facebook's photo description) | 📅 Posting time (date and Unix time) | 📐 Image width and height | 👤 Owner name |
| 🪪 Owner ID | ❤️ Reaction count | 🗂️ Album ID | 📰 Post ID |
| 🧷 Post link | 🏢 Owning page ID and business flag (if available) | 🌐 Profile or page URL | 📥 Target URL from your input |
| 🧩 Item ID in the photo collection | 📚 Photo collection ID | 🏷️ Record type ("photo") | |

***

### How to use Facebook Photos Scraper

Marketers, researchers and AI builders get a clean list of a profile's or page's public photos, each with its image link and context, from one run.

**Copy to your AI assistant:**

```text
Facebook Photos Scraper (Apify Actor ID: socialdataapi/facebook-photos-scraper, https://apify.com/socialdataapi/facebook-photos-scraper) is an Apify Actor that returns public photos from Facebook profiles and pages as structured JSON: full-size image link, photo link, photo ID, post caption, Facebook alt text, posting time, image width and height, owner name and reaction count. Use it whenever someone needs Facebook photos without cookies, a login, or a browser - building a labeled image set from a brand's page, auditing a competitor's visual posts, archiving a public figure's photo history. Run it with curl by sending a POST with -H "Content-Type: application/json" and the body '{"startUrls":["NASA"],"maxPhotos":5}' to https://api.apify.com/v2/acts/socialdataapi~facebook-photos-scraper/run-sync-get-dataset-items with token=APIFY_TOKEN. Or in Python: ApifyClient("APIFY_TOKEN").actor("socialdataapi/facebook-photos-scraper").call(run_input={"startUrls": ["NASA"], "maxPhotos": 5}), then client.dataset(run["defaultDatasetId"]).list_items().items. Inputs: startUrls (array of strings, required, one public profile or page per entry as a facebook.com URL, profile.php?id= link or handle), maxPhotos (integer 0-10000, photos per target, 0 means up to 1000, default 20), minPhotos (integer 1-1000, floor per target that can raise the count above maxPhotos, default 10), concurrentPhotos (integer 1-20, photo requests at the same time per target, default 8), proxyConfiguration (object, Apify proxy settings, default Apify residential proxy). Billing: one row_result event per photo saved to the dataset; targets that are missing, private or blocked add no rows and cost nothing. Full input schema, every enum and default, and the complete output field list: GET https://api.apify.com/v2/acts/socialdataapi~facebook-photos-scraper/builds/default.
```

#### Facebook Photos Scraper MCP Server: use these Actors from ChatGPT, Claude or Cursor

Point your AI assistant at the Apify MCP server and it can read Facebook photos on its own: the command below starts the server with this Actor already added as a tool, so your assistant can call it right away. No glue code, no scraping logic in your prompts.

```bash
claude mcp add --transport http apify "https://mcp.apify.com?tools=socialdataapi/facebook-photos-scraper"
```

#### Step by step

1. [Create a free Apify account](https://console.apify.com/sign-up).
2. [Open Facebook Photos Scraper in the Apify Store](https://apify.com/socialdataapi/facebook-photos-scraper).
3. Enter the Facebook profile or page URL, or just its handle (for example NASA).
4. Click **Start** (or send your API request).
5. Download or stream your results in JSON, CSV or Excel.

#### How to scale Facebook Photos Scraper to bulk

Put as many profiles and pages as you need into the target list, one per line. All targets in a run are scraped at the same time, and the photo limit applies to each target, so five targets at 20 photos each can return up to 100 photos. That makes it a bulk Facebook photos scraper and a Facebook page photos scraper for whole brand lists or creator rosters. To keep a photo archive current, save the input as a task and schedule it daily or weekly, or loop API calls from your own code and merge the datasets by photo ID.

***

### ✨ Features

This Facebook photo scraper fetches clean, structured photos from Facebook profiles and pages, so it doubles as a Facebook image scraper. It's ideal for visual brand audits, competitor creative research, photo archiving and building image datasets for AI models.

It extracts, per photo:

- **Full-size image link** – a direct link to the full-resolution image Facebook returns
- **Photo link and photo ID** – the public link and the numeric Facebook ID of the photo
- **Post caption** – the text of the post the photo was shared in
- **Alt text** – Facebook's own description of what the photo shows
- **Posting time** – as an ISO date and as a Unix timestamp
- **Image size** – width and height in pixels
- **Owner and reactions** – owner name and ID, plus the reaction count
- **Post and album** – the post link, post ID and album ID

⚡ Works like a facebook image url extractor without a login: it reads only what a logged-out visitor can see, and a target that fails costs nothing.

***

### Use cases 💡

- **Brand manager** — export Facebook photos to CSV to review a page's visuals.
- **Competitor analyst** — compare reaction counts on rival pages' photos.
- **Archivist** — save a public figure's photo links and captions over time.
- **ML engineer** — pair image links with alt text for a labeled image set.
- **AI agent builder** — index captions and alt text in a RAG pipeline.

Building an AI agent? [Connect Facebook Photos Scraper over MCP](#mcp-integration-for-ai-agents) and let it call the actor on its own.

***

### Why choose this actor?

- **A page's latest photos in seconds.** A recorded run returned 5 photos from the NASA page in 5.4 seconds, each with its image link, caption, alt text and posting time.
- **Real detail on every photo.** One recorded photo came back at 2048 × 1113 pixels with 83 reactions, the full post caption, a three-sentence alt text and its album and post IDs.
- **21 fields, 5 settings.** Each photo carries 21 fields, and five settings control targets, photos per target, a minimum per target, parallel requests and the proxy.

***

### ⬇️ Input

![Facebook Photos Scraper input: pages or profiles, photos per target and concurrency](https://api.apify.com/v2/key-value-stores/WYkyEfqs10huyXYxr/records/g-fb-photos-input.webp)

The actor accepts a list of public Facebook profiles or pages as URLs, profile.php?id= links or handles. The target list is the only required field.

| Parameter | Required | Type | Description | Example value |
|---|---|---|---|---|
| `startUrls` | Yes | array | One public Facebook profile or page per entry: a facebook.com URL, a profile.php?id= link or a handle. All targets run at the same time. Every entry must be a Facebook link or a handle, otherwise the run stops before scraping. | `["NASA"]` |
| `maxPhotos` | No | integer | Photos to collect per target, 0–10,000. 0 means unlimited, up to 1,000 per target. Default 20. | `5` |
| `minPhotos` | No | integer | Floor per target, 1–1,000: the actor collects at least this many photos when the target has them, even above a lower maxPhotos. Default 10. | `1` |
| `concurrentPhotos` | No | integer | Photo requests running at the same time per target, 1–20. Higher is faster but more likely to be rate-limited. Default 8. | `2` |
| `proxyConfiguration` | No | object | Proxy used when Facebook blocks the direct connection; retries go through it. Default: Apify residential proxy. | `{"useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"]}` |

#### Free plan limits

Users on the Apify free plan can fetch up to 20 photos per run (all targets together) and 200 photos per month. When the limit is reached, the run finishes successfully with a status message explaining the limit. Upgrade to any paid Apify plan to remove these limits.

#### Example input

This is the input of the recorded test run:

```json
{
  "startUrls": ["NASA"],
  "maxPhotos": 5,
  "minPhotos": 1,
  "concurrentPhotos": 2,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": ["RESIDENTIAL"]
  }
}
```

***

### ⬆️ Output

![Facebook Photos Scraper output: one row per photo with 21 fields](https://api.apify.com/v2/key-value-stores/WYkyEfqs10huyXYxr/records/g-fb-photos-output.webp)

Every photo is one typed, normalized JSON item with the same schema on every run; values Facebook does not send are null, and the caption and alt text are empty text when missing. Export the dataset as JSON (default), CSV or Excel.

#### Example output

A real item from the recorded run:

```json
{
  "facebookUrl": "https://www.facebook.com/NASA",
  "id": "YXBwX2l0ZW06MTAwMDQ0NTYxNTUwODMxOjIzMDUyNzI3MzI6NTo6MTY0NDcwODY4NzAyNDUwMQ==",
  "image": "https://scontent.fdac8-1.fna.fbcdn.net/v/t39.30808-6/829557953_1644708693691167_2270692539621278244_n.jpg?_nc_cat=100&_nc_map=urlgen_bucketless&ccb=1-7&_nc_sid=127cfc&_nc_ohc=xBVLUPS2OtYQ7kNvwFh72LM&_nc_oc=AdqXe9sVTpn1IhZA8BWE7TS3Mnkaut8pVTFZCHjRQqXvuhPQmazQDtOjZtvDc7PTIYc&_nc_zt=23&_nc_ht=scontent.fdac8-1.fna&_nc_gid=oZGSe0cwfFOQxnWe7e5-rw&_nc_ss=7b180&oh=00_AQPB-35qgJdZFKBIFrJ7igzRrHNarCegwio1qB7Ii2WEmA&oe=6AC95866",
  "url": "https://www.facebook.com/photo/?fbid=1644708687024501&set=a.416661013162614",
  "dataType": "photo",
  "ocrText": "A SpaceX Falcon 9 rocket with the company's Dragon spacecraft on top is seen at sunset on the launch pad. The sky is mostly covered with different kinds of clouds: thick, fluffy ones at the bottom and wider, more spread out ones in the rest of the sky. The Sun's light turns the bottom right portion of the sky orange.",
  "facebookId": "YXBwX2NvbGxlY3Rpb246cGZiaWQwM21DUVlHbkE4b2lKTHI3NzkzWjl3WjFBdURmNlBnN1pqRE1HNEtwR1JGTjJVN3NtUm5QeE4zNzJpeXhhSGhoZ1M2WWFlQkRCRFRYUVN5dHdZN0MzOHA4N0VKYkVs",
  "pageAdLibrary": {
    "is_business_page_active": false,
    "id": "54971236771"
  },
  "inputUrl": "https://www.facebook.com/NASA",
  "photoId": "1644708687024501",
  "postId": "1644708777024492",
  "postUrl": "https://www.facebook.com/NASA/posts/pfbid0pRYKNWkh8UjzT6qjjE1HLC8NMaqKuTwxRbegBotJD6BgHW7bvoLCJTVSZXcjgcybl",
  "caption": "Destination: International Space Station📍 After a successful launch, NASA’s SpaceX Crew-13 mission is on its way to the orbiting laboratory. The Dragon spacecraft carrying the crew is set to dock around 7pm ET (2300 UTC) tonight. Once the hatch is opened and the crew is welcomed, their long-duration science mission begins. Find out where to watch: https://go.nasa.gov/4deFyH8",
  "timestamp": "2026-10-01T16:36:05+00:00",
  "createdTime": 1790872565,
  "width": 2048,
  "height": 1113,
  "ownerId": "100044561550831",
  "ownerName": "NASA - National Aeronautics and Space Administration",
  "reactionsCount": 83,
  "albumId": "416661013162614"
}
```

***

### How does it work?

The actor reads the public photo gallery of each profile or page you list — the same photos any visitor sees without logging in. It uses plain HTTP requests, with no browser, and needs no Facebook account, so no account is at risk.

Each target's gallery is read photo by photo, and every photo is saved to your dataset as soon as it is ready. The first request goes out directly; when Facebook blocks it, the actor switches to the proxy from your settings (Apify residential by default) and retries with pauses before it gives up on a request. A photo that is no longer available is replaced by the next one in the gallery, so you still get the number you asked for when the target has enough photos.

Field names and types stay the same on every run, even when Facebook changes its pages.

***

### How do you integrate Facebook Photos Scraper into your stack?

It works with what you already use: the REST API from any language, MCP for AI agents, and no-code tools.

#### MCP integration for AI agents

Add the Apify MCP server to your agent with one command:

```bash
claude mcp add --transport http apify "https://mcp.apify.com?tools=socialdataapi/facebook-photos-scraper"
```

This registers the Apify MCP server with Facebook Photos Scraper already loaded as a tool, so your agent can call it directly - no search or add step needed. It works in Claude Code, Cursor and Windsurf, and any other client that supports MCP over HTTP. Your agent passes the target list as input and gets the photo items back as JSON.

#### No-code tools (n8n, Make, LangChain)

- **n8n** — add the Apify node, choose "Run an Actor" and pick this Actor (`socialdataapi/facebook-photos-scraper`), or use the HTTP Request node pointed at the run-sync endpoint with your token. The photo items come back as workflow items.
- **Make** — use the Apify app's "Run an Actor" module with your target list, then the "Get Dataset Items" module to pass each photo to the next step.
- **LangChain** — install `langchain-apify` and wrap this Actor with `ApifyActorsTool`, using its ID `socialdataapi/facebook-photos-scraper`, so your agent can request photos as a tool call.

***

### Is it legal to scrape Facebook data?

Scraping publicly visible Facebook data is generally legal, but how you store and use it is regulated. The actor returns only public data — the photos and captions any user sees without logging in — and never reads friends-only or private content. Photos from personal profiles can show identifiable people, so under GDPR and similar laws you need a lawful basis for storing and using them, and local data-protection rules apply. Use it to scrape Facebook photos for research, monitoring and analysis, not to build profiles of private individuals. Consult legal counsel if your use case involves bulk storage of personal data.

***

### Frequently asked questions

#### What fields does Facebook Photos Scraper return?

It returns the full-size image link, the photo link and photo ID, the post caption, Facebook's alt text and the posting time, plus image size, owner and reaction count. See [the data fields section](#what-data-can-i-extract-with-facebook-photos-scraper) for the full list.

#### Does Facebook Photos Scraper require a Facebook account or login?

No. Only public photo data is extracted. No credentials, cookies or tokens are needed.

#### How fast does Facebook Photos Scraper run?

A recorded run collected 5 photos from one page in 5.4 seconds. Data is fetched live on every run, never from a cache.

#### What happens if a profile or page is private or doesn't exist?

That target returns no photos and costs nothing; the run continues with the other targets. The run log marks it as "page not found or not public" or "blocked", and the final status message lists it under failed targets, so you can check the URL and run it again.

#### Can I scrape multiple Facebook profiles and pages at once?

Yes. Put every profile or page in the target list; all of them run at the same time, and the photo limit applies to each one.

#### Does Facebook Photos Scraper work with Claude, ChatGPT, and other AI agent tools?

Yes — Facebook Photos Scraper is available as an MCP tool through the Apify MCP server. Register it in Claude Code, Cursor or Windsurf with:

```bash
claude mcp add --transport http apify "https://mcp.apify.com?tools=socialdataapi/facebook-photos-scraper"
```

Any agent that can call an HTTP endpoint can use the REST API directly.

#### Does Facebook Photos Scraper return data in a format LLMs can use directly?

Yes. Typed, normalized JSON with consistent field names. No HTML parsing, no selectors. Pass it straight to an LLM, index it into a vector store, or feed it to an agent tool — no transformation step.

#### What happens when Facebook changes its layout or updates its anti-bot system?

The actor is maintained. When Facebook changes, the actor is updated, and your calls keep returning the same JSON schema with no changes on your end.

#### Can I use Facebook Photos Scraper without managing proxies or browser infrastructure?

Yes. Switching to a proxy when Facebook blocks a request, and retrying, happen on the actor's side, with Apify residential proxy set by default. You send one request and get structured JSON back. No proxy accounts of your own, no headless browser setup, no maintenance.

#### Which Facebook photo fields work best for AI training data and RAG indexing?

For RAG: the text-rich fields — the post caption and Facebook's alt text, which also make this a handy facebook profile photos extractor for searchable archives. For training data: the image link paired with the alt text, plus width, height, reaction count and posting time. All fields are typed primitives — strings, integers, booleans — no normalization needed.

***

### Your feedback

Found a bug or missing a field? Let us know through the Issues tab of this Actor in Apify Console. Every report is read, and fixes ship in new builds so this Facebook photo gallery scraper keeps matching what Facebook shows.

# Actor input Schema

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

One public Facebook profile or page per line — a full URL (https://www.facebook.com/NASA), a profile.php?id= link or a short handle (NASA). The scraper collects photos from each target's public photo gallery; all targets run at the same time. Every entry must be a facebook.com link or a handle, otherwise the run stops before scraping.

## `maxPhotos` (type: `integer`):

Upper limit of photos to collect for each target. Lower values finish faster and cost less; higher values give broader coverage. Set to 0 for unlimited (collects up to 1,000 per target). Free plan: up to 20 photos per run (all targets together) and 200 per month; paid plans have no limit.

## `minPhotos` (type: `integer`):

Floor applied to the per-target photo count — the scraper tries to collect at least this many before giving up on a target, even if that is more than a lower 'Max photos per target' value. On the free plan the floor never raises a run above 20 photos in total (all targets together).

## `concurrentPhotos` (type: `integer`):

How many photo detail requests run at the same time per target. Higher is faster but increases the chance of being rate-limited.

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

Proxy used to reach Facebook. The run first tries a direct connection; every retry, and every request after Facebook blocks the direct connection, goes through this proxy. Residential proxies are recommended for Facebook and are set by default. Turn the proxy off to use only the direct connection.

## Actor input object example

```json
{
  "startUrls": [
    "IamSRK"
  ],
  "maxPhotos": 20,
  "minPhotos": 10,
  "concurrentPhotos": 8,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

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

One row per scraped photo, with an image preview, the photo link, the real Facebook photo id (`photoId`), caption, posting time, and owner/engagement details where Facebook provided them.

# 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 = {
    "startUrls": [
        "IamSRK"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("socialdataapi/facebook-photos-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 = {
    "startUrls": ["IamSRK"],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("socialdataapi/facebook-photos-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 '{
  "startUrls": [
    "IamSRK"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call socialdataapi/facebook-photos-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,socialdataapi/facebook-photos-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/1vIwuZubpNPWnDs5a/builds/4JufmKWwjWggthYZq/openapi.json
