Facebook Marketplace is one of the largest peer-to-peer selling platforms in the world, but it doesn't offer a public API. If you've ever wanted to pull listing data into your own app — for a deal-finder, a price comparison tool, or a resale inventory tracker — you know the pain.
The Facebook Marketplace Search API solves this. One GET request, and you get structured listing data back: titles, prices, images, locations, and more.
How It Works
The API exposes a single, clean endpoint:
GET /api/facebook-marketplace-search/search?query={keyword}
Pass a keyword like iphone 15 or couch, and you get back an array of matching Marketplace listings with details you can actually work with.
Quick Code Example
Here's how to search for listings using fetch() in JavaScript:
const response = await fetch(
'https://facebook-marketplace-search.p.rapidapi.com/api/facebook-marketplace-search/search?query=macbook+pro',
{
method: 'GET',
headers: {
'x-rapidapi-key': 'YOUR_RAPIDAPI_KEY',
'x-rapidapi-host': 'facebook-marketplace-search.p.rapidapi.com'
}
}
);
const data = await response.json();
data.results.forEach(listing => {
console.log(`${listing.title} — $${listing.price}`);
console.log(` Location: ${listing.location}`);
});
That's it — no scraping, no browser automation, no auth tokens to manage.
What Can You Build With This?
- Deal alert bots: Monitor listings for items under a target price and send yourself a notification via Discord, Slack, or email.
- Price comparison dashboards: Pull Marketplace listings alongside eBay or Craigslist data to show users the best local deals.
- Resale research tools: Track what items sell for in different areas to find arbitrage opportunities.
- Inventory sourcing: If you flip items, automate your sourcing pipeline by scanning for underpriced goods in bulk.
Why Use an API Instead of Scraping?
Scraping Marketplace is brittle. Facebook changes its DOM constantly, blocks automated browsers, and requires login. An API gives you:
- Stable, structured JSON responses
- No maintenance when the site changes
- Clean integration into any stack
Try It
The API is available on RapidAPI with a free tier so you can test it immediately:
Facebook Marketplace Search on RapidAPI
Subscribe, grab your key, and start pulling listings in minutes. If you build something cool with it, I'd love to hear about it in the comments.
Top comments (0)