Facebook Post Search Scraper
Pricing
from $6.00 / 1,000 matching post returneds
Facebook Post Search Scraper
Search public Facebook page, profile, and group posts by keyword. Returns only posts whose text or author matches your terms, with author, timestamp, engagement counts, media, and the matched terms. Cookieless, no login. MCP-ready.
Pricing
from $6.00 / 1,000 matching post returneds
Rating
0.0
(0)
Developer
Khadin Akbar
Maintained by CommunityActor stats
0
Bookmarked
12
Total users
5
Monthly active users
5 days ago
Last modified
Categories
Share
Facebook Post Search Scraper is an Apify Actor for searching public Facebook page, profile, and group posts by keyword. It accepts search terms plus the source URLs to search within, and returns one dataset record for each matching post. Each record can include the source URL, canonical post URL, author name and author URL, post text, matched terms, matched fields, timestamp, engagement counts, media, external links, and the provider that returned the row. It runs cookieless, requires no login, and is usable through Apify MCP.
Best fit and connected workflows
Use this Actor when you already have a keyword or phrase and want matching public posts from specific Facebook sources. It fits workflows such as:
- Brand or campaign monitoring across selected pages and groups
- Competitor or market watch on public Facebook posts
- Community research from public groups by topic or keyword
- Lead discovery from posts that mention hiring, buying intent, recommendations, or product interest
- AI agent pipelines where a tool returns structured post matches for follow-up reasoning
A practical workflow connection is discovery followed by comment review. Run this Actor first to find the public posts that match your search terms, then pass selected postUrl values into Facebook Post Comments Scraper when you want comment-level context for those same records. That follow-up step is a natural fit when a matched post is relevant and you want to inspect the discussion around it.
One practical scenario
Maya is tracking public Facebook activity for a product launch. She starts with the NASA page and a public group URL, and enters search terms like "launch" and "moon" with match mode set to any. The Actor returns matching rows with postUrl, authorName, timestamp, reactionsCount, commentsCount, sharesCount, media, and matchedTerms. Maya opens the canonical post URL for the relevant match and then shares the selected rows with her team for review.
Input
| Field | Type | Required | Description |
|---|---|---|---|
searchTerms | array | Yes | Keywords or phrases to search for in each post. A post is returned when it matches the configured match mode. |
startUrls | array | Yes | Up to 10 public Facebook page, profile, group, or direct post URLs to search within. |
matchMode | string | No | Combines multiple terms as any or all. Default: any. |
matchFields | array | No | Search text, author, or both. Default: text. |
caseSensitive | boolean | No | Uses exact letter case when matching terms. Default: false. |
useRegex | boolean | No | Treats each term as a JavaScript regular expression. Default: false. |
resultsLimit | integer | No | Maximum number of matching posts returned across all sources. Default: 50. |
maxPostsScannedPerSource | integer | No | Maximum recent posts scanned per source while looking for matches (1–60). Default: 60. |
onlyPostsNewerThan | string | No | Optional lower date filter, such as an ISO date. |
onlyPostsOlderThan | string | No | Optional upper date filter, such as an ISO date. |
fallbackProvider | string | No | Managed data provider selection: auto, scrapeCreators, or sociaVault. |
proxyConfiguration | object | No | Proxy configuration. Apify Proxy is the default. |
Focused input example
{"searchTerms": ["hiring", "remote"],"startUrls": [{ "url": "https://www.facebook.com/NASA" },{ "url": "https://www.facebook.com/groups/yourgroupid" }],"matchMode": "any","matchFields": ["text"],"caseSensitive": false,"useRegex": false,"resultsLimit": 25,"maxPostsScannedPerSource": 60,"fallbackProvider": "auto"}
Output
Each dataset item represents one matching Facebook post.
| Field | Type | Description |
|---|---|---|
sourceUrl | string | Facebook source URL that produced the match. |
postUrl | string | Canonical Facebook URL for the matching post. |
postId | string or null | available Facebook post, story, or video ID. |
authorName | string or null | Author or page name that published the post. |
authorUrl | string or null | Canonical Facebook author or page URL. |
text | string or null | Post caption or body text searched against the terms. |
matchedTerms | array | Search terms that matched the post. |
matchedFields | array | Fields that matched, such as text or author. |
timestamp | string or null | ISO 8601 publish time when available. |
timestampText | string or null | Original date text returned by the provider. |
reactionsCount | integer or null | available reactions or likes count. |
commentsCount | integer or null | available comments count. |
sharesCount | integer or null | available shares count. |
media | array | Image or video URLs attached to the post. |
externalLinks | array | Outbound non-Facebook links found in the post text. |
scrapeSource | string | Managed provider that returned the post. |
scrapedAt | string | ISO 8601 timestamp when the record was emitted. |
Illustrative output record
{"sourceUrl": "https://www.facebook.com/NASA","postUrl": "https://www.facebook.com/NASA/posts/1234567890","postId": "1234567890","authorName": "NASA","authorUrl": "https://www.facebook.com/NASA","text": "We are hiring for a remote communications role.","matchedTerms": ["hiring", "remote"],"matchedFields": ["text"],"timestamp": "2026-01-15T10:20:30Z","timestampText": "January 15","reactionsCount": 120,"commentsCount": 14,"sharesCount": 8,"media": ["https://example.com/image.jpg"],"externalLinks": ["https://example.com/jobs"],"scrapeSource": "scrapecreators","scrapedAt": "2026-01-15T10:21:00Z"}
How it works
The Actor searches public Facebook page, profile, and group posts by keyword within the sources you provide. It scans recent posts from each source, applies your matching rules locally, and returns only the posts that match. Matching can use any-term or all-term logic, can search post text and author name, and can be case-sensitive or regex-based when you want tighter filtering.
The implementation uses managed data providers. In auto mode, ScrapeCreators is used first and SociaVault is used second. Provider keys are configured by the actor owner, so you only supply the search criteria and source URLs.
Pricing
This Actor uses Pay per event plus Apify platform usage. The billed events are:
- Actor start
- Source searched
- Matching post returned
For example, a run that searches five sources and returns forty matching posts includes one actor-start event, five source-searched events, and forty matching-post events, plus Apify platform usage. For current pricing and exact event rates, check the live Pricing tab on the Actor page.
Use with AI agents (MCP)
This Actor is available through Apify MCP as a structured tool for finding public Facebook post matches. The exact Actor identity is khadinakbar/facebook-post-search-scraper.
Tool description: search public Facebook page, profile, and group posts by keyword, then return matching posts with provenance fields such as sourceUrl, postUrl, matchedTerms, matchedFields, scrapeSource, and scrapedAt.
Search these public Facebook sources for posts mentioning "hiring" or "remote". Return the matching records with author, timestamp, engagement counts, media, matched terms, and canonical post URLs. Use the source URLs I provide and keep the result scoped to those pages and groups.
Output interpretation: each returned dataset item is one matching post. Use matchedTerms to see which search terms triggered the row, matchedFields to see whether the match came from text or author name, and scrapeSource to identify which managed provider returned the record.
Provenance: sourceUrl tells you where the post was searched, postUrl identifies the canonical post, and scrapedAt records when the row was emitted.
Scope and pagination: resultsLimit caps the total number of matching posts returned, while maxPostsScannedPerSource controls how many recent posts are read from each source, up to 60. A run accepts at most 10 unique sources so runtime and provider requests remain bounded.
Cost guidance: each returned match is a billed post-matched event, and each source that is scanned is billed as a source-searched event. Use resultsLimit as your primary cost cap.
Outcome guidance: if a managed provider explicitly returns an empty public-post collection, the run ends as VALID_EMPTY with no source or match event. A provider block, network failure, malformed response, or private/login-only source remains UPSTREAM_FAILED when no source could be searched. OUTPUT and RUN_SUMMARY include safe provider-attempt statuses such as returned_records, confirmed_empty, opaque_response, and error_envelope; they never include a provider key or raw upstream error text. This distinction never creates a dataset row.
API example
import osfrom apify_client import ApifyClientclient = ApifyClient(os.environ["APIFY_TOKEN"])run = client.actor("khadinakbar/facebook-post-search-scraper").call(run_input={"searchTerms": ["hiring", "remote"],"startUrls": [{"url": "https://www.facebook.com/NASA"}],"matchMode": "any","matchFields": ["text"],"resultsLimit": 10,"maxPostsScannedPerSource": 60})dataset_id = run["defaultDatasetId"]items = client.dataset(dataset_id).list_items().itemsfor item in items:print(item["postUrl"], item.get("matchedTerms"))
Best results and outcome guidance
Use search terms that match how people phrase the post text or author name. Start with matchFields: ["text"] for topic discovery, then add author when the page or profile name itself matters.
For broader monitoring, keep matchMode: "any". For tighter retrieval, use matchMode: "all" and, when needed, useRegex: true for pattern-based searches. Increase maxPostsScannedPerSource up to 60 when the keyword is rare and you want the Actor to read deeper into recent posts.
If you want only newer or older content, set the date filters before running so the returned dataset stays aligned with your review window.
Continue the workflow
- Then use Facebook Posts Scraper to continue from Facebook Post Search Scraper discovery into content data for the selected records.
- Then use Facebook Search Scraper to extend Facebook Post Search Scraper research with a complementary discovery contract.
Design note
I found that the dataset contract requires sourceUrl, postUrl, matchedTerms, scrapeSource, and scrapedAt on every record, so the README should present those fields as the core output for downstream use.
FAQ
When should I use this Actor instead of a general Facebook scraper?
Use this Actor when you already know the keyword or phrase you are looking for and want only matching posts from selected public sources.
Can I search by the page or author name?
Yes. Set matchFields to include author when the author name is part of your filter.
How do I search multiple terms?
Use matchMode: "any" to return posts that match at least one term, or matchMode: "all" to return posts that match every term.
What sources work well?
Public Facebook pages, public profiles, public groups, and direct public post URLs are accepted as sources.
How can I continue from discovery to deeper analysis?
Use the returned postUrl values as inputs to downstream workflows. When you want comment-level context for a discovered post, connect the result to Facebook Post Comments Scraper. This is a natural next step when a matching post looks relevant and you want to review the discussion around it.
Responsible use
Use this Actor only on publicly available Facebook data and in ways that comply with Facebook's Terms of Service and applicable data protection laws. Keep the scope limited to the public pages, profiles, and groups you intentionally provide, and review how you handle personal data before storing or sharing the results.