Skip to main content
MCP server CX Codex

meta-ads — Claude Code MCP server: ads and setup

Connects the Meta Marketing API to an AI coding agent for Facebook and Instagram campaigns, audiences, creatives, insights, and catalogs.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env META_ADS_ACCESS_TOKEN=<META_ADS_ACCESS_TOKEN> --env META_AD_ACCOUNT_ID=<META_AD_ACCOUNT_ID> --env META_APP_ID=<META_APP_ID> --env META_APP_SECRET=<META_APP_SECRET> --env META_BUSINESS_ID=<META_BUSINESS_ID> --transport stdio meta-ads -- npx -y @mikusnuz/meta-ads-mcp
Open on GitHub

What meta-ads does

meta-ads connects Claude Code to Meta Marketing API v26.0. The server exposes 134 tools for campaigns, ad sets, ads, audiences, creatives, insights, and catalogs. An agent can create campaign assets, upload images, inspect account performance, or search public ads in the Facebook Ad Library.

It also supports asynchronous reports for larger date ranges, controlled tests between ad sets, and automated rules for pausing underperforming ads. Audience and catalog workflows are included. The setup needs Node.js 20 or later in the MCP host’s npx environment, a Meta Marketing API access token, and a numeric ad account ID without the act_ prefix. Without Node.js 20, the server will not start.

What it helps with

  • create a Facebook campaign with ad sets and ads
  • check account or campaign performance for a date range
  • pause campaigns whose ROAS falls below a threshold
  • run an A/B test between two ad creatives
  • build a customer audience and a lookalike audience

Example prompts for the agent

  • Create a Facebook campaign, ad set, and ad with a suitable creative.
  • Check today’s campaign performance and identify ads with low ROAS.
  • Search the Facebook Ad Library for public ads from a competitor.

How to install meta-ads

Platform CLI

claude mcp add --env META_ADS_ACCESS_TOKEN=<META_ADS_ACCESS_TOKEN> --env META_AD_ACCOUNT_ID=<META_AD_ACCOUNT_ID> --env META_APP_ID=<META_APP_ID> --env META_APP_SECRET=<META_APP_SECRET> --env META_BUSINESS_ID=<META_BUSINESS_ID> --transport stdio meta-ads -- npx -y @mikusnuz/meta-ads-mcp

Replace <…> with your own values. 1 more environment variable is in the server README

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about meta-ads

How do I install meta-ads in Claude Code?

Run `claude mcp add --env META_ADS_ACCESS_TOKEN=<META_ADS_ACCESS_TOKEN> --env META_AD_ACCOUNT_ID=<META_AD_ACCOUNT_ID> --env META_APP_ID=<META_APP_ID> --env META_APP_SECRET=<META_APP_SECRET> --env META_BUSINESS_ID=<META_BUSINESS_ID> --transport stdio meta-ads -- npx -y @mikusnuz/meta-ads-mcp`.

What does meta-ads do?

This MCP server connects an AI agent to Meta Marketing API v26.0. Its 134 tools cover Facebook and Instagram campaigns, audiences, creatives, performance data, catalogs, and public ad-library searches.

What does meta-ads require to run?

You need Node.js 20 or later, META_ADS_ACCESS_TOKEN, and META_AD_ACCOUNT_ID without the act_ prefix. META_APP_ID, META_APP_SECRET, and META_BUSINESS_ID support additional functions.

Similar MCP servers

All MCP servers for Marketing and content →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor