Skip to content
GUIDES#Meta Ads MCP#Facebook Ads AI#MCP for marketers

Connect Meta Ads to Claude Code via MCP: The Complete Guide to AI-Powered Campaign Management

Instead of jumping between Ads Manager and Excel, you talk to your ad account directly: a morning report, spotting wasted spend, even creating a campaign. Here is how to connect Meta Ads to Claude Code, and what we learned from managing real budgets this way.

Yaakov Tzedek
Yaakov Tzedek · AI expert·14 min read
Claude Code screen managing a Facebook Ads campaign via an MCP connection
THE BOTTOM LINE
  • Practical guide: how to connect your Meta (Facebook and Instagram) ad account to Claude Code via MCP, manage campaigns in plain language, and which safety rules you must set up. Includes a real case study.
Campaign management in plain language: reports, comparisons, budget changes, and campaign creationWhat you get
Meta ad account + Claude Code + MCP connectionRequirements
Works great: queries and reports in any language, raw data from Meta in EnglishLanguage
Every AI-created campaign is created in PAUSED mode, and a human approves activationThe iron rule
DID YOU KNOW?

On the very first account we connected for a client, the agent discovered within minutes that an account with over 300,000 ILS in cumulative spend was running with zero conversion tracking. Nobody had noticed, because everything looked fine in the regular dashboard.

You can connect your Meta (Facebook and Instagram) ad account directly to Claude Code through the MCP protocol and manage campaigns in plain language: "What did I spend this week and where," "Compare these two ads," "Create a traffic campaign at 50 ILS per day, paused." We have been managing real client budgets this way for two months. In this guide: how to connect, which prompts work day to day, the safety rules you must set up before giving AI access to money, and one real case study, including the mistakes.

What Is MCP and Why Does It Change Campaign Management?

MCP (Model Context Protocol) is an open protocol that connects an AI model to external tools: databases, advertising platforms, CRMs. Instead of copying screenshots from Ads Manager into a chat, the model accesses the data itself and returns a reasoned response.

The practical difference is significant. A regular chat can offer general campaign advice; Claude Code with an MCP connection sees your campaigns: yesterday's spend, the ad generating expensive clicks, the audience that is burning out. And beyond reading, on accounts where it has been enabled, it also writes: creating a campaign, ad set, and ad.

If the concept is new to you, we have written a complete guide to MCP that explains the protocol from the ground up.

What Can You Do After Connecting?

The short answer: almost everything you do in Ads Manager, in plain language. In practice, these are the uses that come up for us every week:

  • Morning report in Hebrew: spend, impressions, clicks, and conversions from yesterday, across all accounts, in one message
  • Finding waste: "Which ad sets spent more than 100 ILS with zero conversions in the last week?"
  • Creative comparison: ad-versus-ad performance, including copy and visuals
  • Infrastructure checks: Is conversion tracking connected? Is the pixel firing? Is any campaign paused because of a payment issue?
  • Campaign creation: A complete campaign (campaign, ad set, creative, ad) created in paused mode and waiting for your approval
  • Budget and status changes: Raise, lower, pause, and activate, with a single command

How Do You Connect Meta Ads to Claude Code? (Step by Step)

There are two paths, and the choice depends on the access you have. In both cases the setup is one-time and takes less than an hour.

Path 1: Meta's MCP Connection

Meta is gradually opening MCP access to ad accounts, with read and write permissions. Here is how it works:

  1. Open the MCP settings in Claude Code: run <code dir="ltr">claude mcp add</code> in the terminal, or use the Connector interface
  2. Authorize access to your ad account in Meta's permissions window (OAuth), just as you would authorize any app
  3. Test the connection: write to Claude "Show me my ad accounts" and confirm the account appears
  4. Test write permission: on some accounts, campaign creation has not yet been enabled by Meta. In that case, reading and analysis work, and creation will be enabled later

Path 2: MCP Server with a Graph API Token

For those who want full control, or whose account has not yet received write capability through the official path:

  1. Create an app in Meta's developer portal and connect it to Business Manager
  2. Create a System User with <code dir="ltr">ads_read</code> permissions (and for writing: <code dir="ltr">ads_management</code>) and generate a long-lived token
  3. Install an MCP server for Meta Ads (there are several open-source implementations) and pass it the token as an environment variable
  4. Add the server to Claude Code with <code dir="ltr">claude mcp add</code> and test with a simple prompt

Important: The token is equivalent to access to your money. Store it in environment variables only, never in code or in a chat, and start with read-only permissions until you have built confidence in the process.

Which Prompts Work Day to Day?

The rule: a good campaign-management prompt is specific, time-bounded, and asks for a recommendation with reasoning. Examples we actually run:

  1. "Give me a report on all active campaigns: spend, clicks, and cost per click over the last 7 days. Flag anomalies."
  2. "Compare the two ads in group X. Which one is winning, and why? Recommend which to pause."
  3. "Check whether the account has active conversion tracking. If not, detail what is missing."
  4. "Create a WhatsApp leads campaign, budget 70 ILS per day, audience ages 25 to 54 in Israel. Create everything in paused mode and show it to me for approval."
  5. "What changed since yesterday? Only things that require a decision."

Safety Rules: How Do You Give AI Access to Money Without Losing Control?

The short answer: paused by default, human approval for every financial change, and a log of every action. For us this is anchored in three standing rules:

  • Every campaign is created PAUSED. Always. The AI prepares everything; a human clicks activate. This rule has been absolute for us since day one and has prevented more than one incident.
  • Budget changes go through an approval queue. The recommendation is recorded with reasoning, and it is executed only after explicit approval.
  • Every action is logged. What was decided, why, and what happened afterward. When something is surprising, there is a record to return to.

The simple framing: AI is excellent at seeing everything and suggesting; humans decide on money.

A Field Case Study: What Happened When We Connected a Real Account

A client of ours, a long-established commercial business, came in with two ad accounts: Google and Meta. Years of advertising, a feeling that "something is not working," and zero certainty about why.

We connected the Meta account via MCP and asked Claude Code for an initial review. Within minutes the central finding surfaced: an account with more than 300,000 ILS in cumulative spend and 4.2 million impressions had been running with no conversion tracking at all. On the Google side, the same business was actually tracking dozens of conversions. That meant years of budget decisions on Meta were made in complete blindness, and no dashboard had flagged it, because in the dashboard everything looked "green."

Later that same week we used the connection to create the first campaign built entirely by the agent: a traffic campaign at 50 ILS per day, created in paused mode and waiting for approval. The setup, which takes 20 minutes of manual clicking, took a single prompt.

And now the honest part. During that same period we were also running a leads campaign for our own business, with an automated pipeline that pushed every lead from a Facebook form directly into the CRM within seconds. It sounded perfect, until we asked the agent to review the message history with the leads, and it turned out that 6 out of 8 leads had never received the opening message: the pipeline had sent us a notification but had forgotten to reach out to the lead itself. One missing line of code, days of leads waiting in silence. We fixed it that day, and everyone who had been waiting received a personalized message. The lesson is double: automation without testing is an illusion of order, and an agent that can read your systems is the cheapest and fastest quality-checker you have.

What Does This Mean for Your Business?

If you advertise on Meta, ask yourself three questions. If the answer to any one of them is "not sure," this connection will pay for itself in the first week:

  1. Is conversion tracking actually connected and measuring, or does it just seem that way?
  2. How much time passes from the moment an ad set starts spending until someone notices?
  3. If a lead submits their details in a form, what happens to them in the minutes that follow?

Limitations Worth Knowing in Advance

In full transparency, here is what the connection does not solve:

  • Lead form submissions are not accessible through it. For leads from Instant Forms you need a separate pipeline (a webhook or an automation tool) that pushes them into a CRM.
  • Write capability depends on Meta. Some accounts are still waiting for it to be enabled on their side, and in the meantime those accounts work in read-only mode.
  • The agent is only as good as the guardrails you set for it. Without PAUSED rules and approvals, you have given software open access to the business credit card.

The Bottom Line

Connecting Meta Ads to Claude Code via MCP turns campaign management from hours in front of dashboards into a short conversation with an agent that sees everything: it surfaces infrastructure problems in minutes, builds campaigns from a prompt, and leaves financial decisions with you. The only requirement is discipline: paused mode as the default, human approval for money, and a log for every action.

Want us to set this up for your business, including the safety rules and the leads pipeline? That is exactly what we do in AI implementation consulting for organizations. And if you want to first develop a deeper understanding of how agents like this work, the free intro course for AI implementers includes a full lesson on end-to-end automations.

Related: ChatGPT is also entering advertising, with a format that resembles Meta's "click to WhatsApp": ChatGPT's Next Ad Format: Click to Chat with the Brand's Agent.

Frequently asked questions

Was this article helpful?
Share:WhatsAppLinkedInX
Yaakov Tzedek
WRITTEN BY

Yaakov Tzedek

An Israeli AI lecturer, consultant and implementer who has supported 100+ organizations in AI implementation and lectured for 200+. Official content partner of Meta, Google, Canva and TikTok, featured on Israel's Channel 13.

More about Yaakov →