
How to add Facebook Ads Library MCP Server to Cursor
Search and analyze any brand's public Facebook ads — images, videos, messaging, and competitor strategy. Paste the config into ~/.cursor/mcp.json and restart Cursor.
Last updated June 14, 2026 · 243★ · stdio · apikey
Cursor config for Facebook Ads Library MCP Server
git clone https://github.com/proxy-intell/facebook-ads-library-mcp.git && cd facebook-ads-library-mcp && ./install.sh{
"mcpServers": {
"facebook-ads-library-mcp-server": {
"command": "{{PATH_TO_PROJECT}}/venv/bin/python",
"args": [
"{{PATH_TO_PROJECT}}/mcp_server.py"
]
}
}
}Setup steps
- 1Open Cursor → Settings → MCP → Add new MCP server (or edit ~/.cursor/mcp.json directly).
- 2Paste the Facebook Ads Library MCP Server config below into the "mcpServers" object.
- 3Fill in placeholder secrets, then save.
- 4Cursor reloads MCP servers automatically — check Settings → MCP for a green status dot.
- 5Ask Cursor to use one of Facebook Ads Library MCP Server's tools to confirm it's connected.
Before you start
- Python 3.12+
- pip (Python package manager)
- Claude Desktop or Cursor
- A ScrapeCreators API key (SCRAPECREATORS_API_KEY) for ads data
- Optional: a Google Gemini API key (GEMINI_API_KEY) for video analysis
What Facebook Ads Library MCP Server can do in Cursor
get_meta_platform_idReturns the Meta platform ID given one or many brand names (supports multiple brands in a batch).
get_meta_adsRetrieves ads for specific page(s) by platform ID (supports multiple platform IDs in a batch).
analyze_ad_imageAnalyzes ad images for visual elements, text, colors, and composition (enhanced caching).
analyze_ad_videoAnalyzes a single ad video using Gemini AI for comprehensive insights (enhanced caching).
analyze_ad_videos_batchAnalyzes multiple videos in a single API call for token efficiency (~88% token savings).
get_cache_statsGets statistics about cached media (images and videos) and storage usage.
search_cached_mediaSearches previously analyzed media by brand, colors, people, or media type.
cleanup_media_cacheCleans up old cached media files to free disk space.
Security
Requires a ScrapeCreators API key (SCRAPECREATORS_API_KEY) and, optionally for video analysis, a Google Gemini API key (GEMINI_API_KEY). Keys are stored in a local .env file in the project root and loaded automatically at runtime — they are not passed on the command line. Only public Facebook Ads Library data is queried.
Facebook Ads Library MCP Server + Cursor FAQ
Where is the Cursor config file?
Cursor reads MCP servers from ~/.cursor/mcp.json. Paste the Facebook Ads Library MCP Server config there under the "mcpServers" key and restart the client.
Is Facebook Ads Library MCP Server safe to use with Cursor?
Requires a ScrapeCreators API key (SCRAPECREATORS_API_KEY) and, optionally for video analysis, a Google Gemini API key (GEMINI_API_KEY). Keys are stored in a local .env file in the project root and loaded automatically at runtime — they are not passed on the command line. Only public Facebook Ads Library data is queried.
Do I need to self-host?
No. Proxy (useproxy.dev) offers a fully hosted version of this MCP that works out of the box in ChatGPT, Claude, Manus, and other MCP clients with nothing to install or configure. Self-hosting via the steps above is optional.
What API keys do I need?
A ScrapeCreators API key (SCRAPECREATORS_API_KEY) is required for ads data. A Google Gemini API key (GEMINI_API_KEY) is optional and only needed for video ad analysis. Both are stored in a local .env file.
Which clients are supported for self-hosting?
The README documents an mcpServers config block for both Claude Desktop and Cursor; the server runs over stdio using the project's virtualenv Python.