Skip to content

Connect AI Assistants to Your WordPress Site Using MCP

The Model Context Protocol (MCP) lets you connect AI assistants like Claude Desktop directly to your WordPress sites. This enables AI-powered site management, allowing you to read, analyze, and manage your WordPress content using natural language conversations with your AI assistant.

Want to connect an assistant to your whole InstaWP account (managing sites, backups, plans across your team) instead of a single site? See Connect AI Assistants to Your Account (Account MCP).

In this documentation, we will explore:

Let's get started 🚀

This feature is available in Sandbox plans and above. View Pricing here.

What is MCP?

Model Context Protocol (MCP) is a secure connection protocol that enables AI assistants to interact with your WordPress site. Enabling MCP installs InstaMCP, InstaWP's WordPress MCP server plugin, on your site and gives your assistant a token-authenticated connection to it.

InstaMCP ships 43 tools covering content, Gutenberg blocks, custom fields, taxonomies, media, plugins, themes and diagnostics — plus Skills (reusable playbooks the assistant follows for common jobs) and Memory (durable facts it remembers between sessions). Three power tools (execute_php, db_query, site_files) are off by default and only work once you switch them on.

Why Use MCP?

  • Build and edit, not just read: Create pages, publish posts, upload media, set WooCommerce prices and ACF fields, install and update plugins — from a conversation
  • AI that already knows the job: Built-in Skills teach the assistant how to build a Gutenberg page, work an Elementor/Bricks page, run a pre-launch QA pass, or clean up taxonomies
  • Diagnostics without SSH: site_logs tails your WordPress debug log and PHP error log so the assistant can pin a fatal or a slow page
  • Secure by default: Token-based auth, WordPress role-based permissions, Safe Mode, and the riskiest tools disabled until you enable them

Who Should Use This Feature?

  • Content Creators: Draft, publish, and organize content conversationally
  • Developers & Agencies: Build pages, manage plugins/themes, debug fatals, and run repeatable playbooks across client sites
  • Site Owners: Get insights and make safe changes without digging through wp-admin

How to Enable MCP

Follow these simple steps to enable MCP for your InstaWP site:

Step 1: Navigate to your Sites page in the InstaWP dashboard.

Step 2: Click on the Site name to navigate to the Site Details page and click on MCP Option in Sidebar.

Step 3: In the MCP configuration panel, toggle the Enable MCP switch to ON.

Step 4: Once enabled, InstaWP will automatically:

  • Install and activate the InstaMCP WordPress plugin on your site
  • Generate a secure 64-character authentication token
  • Create your unique connection URL

Step 5: Copy the MCP Connection URL by clicking the copy button next to it.

FieldDescription
MCP Connection URLYour unique, secure URL that connects Claude Desktop to your WordPress site. Keep this URL private as it contains your authentication token.

Security Note: Your MCP connection URL contains a secure authentication token. Do not share this URL publicly. Anyone with this URL can access your site through AI assistants.

Connect in One Click (Add to agent)

Once MCP is enabled, the site's MCP tab shows a Connect WordPress to your AI agent panel — the fastest way to hook up an assistant. Instead of hand-editing a config file, pick your client and InstaWP does the rest: one click for the apps that support it, one copy for the CLIs that don't — and you always see exactly what will be added before anything happens.

Your most-used clients are shown as buttons up front (for example Add to Claude.ai, Add to Claude Code, Add to Cursor, Add to VS Code, and Install in GitHub Copilot), with the rest tucked under More clients. Depending on the client, the button does one of four things:

TypeClientsWhat the button does
One-click installCursor, VS Code (& Insiders), GitHub Copilot, Claude Code (v2.1.91+)Opens the app through a deep link and triggers its own "add connector" consent dialog — approve it and you're connected.
PrefillClaude.ai / Claude Desktop, ChatGPTPrefills the app's Add custom connector dialog and copies the connection URL for you to paste.
Copy command (CLI)Claude Code, Codex, GeminiCopies the exact CLI command to paste into your terminal.
Copy configAntigravity, Claude Desktop, Windsurf, Cline, Roo, Zed, ContinueCopies a ready-made JSON config block to drop into the client's MCP settings.

Just click the button for your tool and follow the prompt it opens — no need to copy the URL by hand. Below the buttons, a Setup guides for AI clients panel covers 14 clients with a pre-filled connection snippet for each.

Security note: For a site, these buttons carry your site's private MCP token (the same one embedded in the connection URL), so the connection authenticates itself. Only use Add to agent on a device you trust — anyone who can use that agent can then reach your site.

Prefer to set things up manually, or using a client that isn't listed? Copy the MCP Connection URL above and follow the step-by-step instructions for Claude Desktop or Claude Code below.

How to Connect Claude Desktop

After enabling MCP in InstaWP, you need to configure Claude Desktop to connect to your WordPress site.

Prerequisites

  • Claude Desktop application installed on your computer (Download Claude Desktop)
  • MCP enabled on your InstaWP site (completed in the previous section)
  • Your MCP connection URL copied to clipboard

Configuration Steps

Step 1: Open the Claude Desktop application on your computer.

Step 2: Go to Settings in Claude Desktop. You can usually find this in:

  • Mac: Claude Desktop menu > Settings (or press Cmd+,)
  • Windows: File menu > Settings (or press Ctrl+,)

Step 3: In Settings, navigate to the Connectors section (or "Integrations" depending on your Claude Desktop version).

Step 4: Click the "Add Custom Connector" or "Add New Connection" button.

Step 5: In the connector configuration dialog:

  • Name: Enter a descriptive name for your site (e.g., "My WordPress Site" or "Client Project Site")
  • Connection URL: Paste the MCP connection URL you copied from InstaWP Step 6: Click "Add" to establish the connection.

Step 7: Claude Desktop will test the connection and confirm if it's successful.

| ✅ Connection Successful! You should see your WordPress site listed in Claude Desktop's connectors. The status should show as "Connected" or "Active".

Verifying the Connection

To verify that Claude Desktop is properly connected to your WordPress site:

Step 1: Start a new conversation in Claude Desktop.

Step 2: Ask Claude a simple question about your site, such as:

  • "Can you access my WordPress site?"
  • "What posts are on my website?"
  • "Tell me about my site structure"

Claude should be able to access your site information and respond with details about your WordPress content.

How to Connect Claude Code

Claude Code is the command-line interface (CLI) version of Claude, designed for developers who prefer working in the terminal. You can connect Claude Code to your InstaWP site using a simple terminal command.

Prerequisites

  • Claude Code CLI installed on your computer (Learn about Claude Code)
  • MCP enabled on your InstaWP site (completed in the "How to Enable MCP" section)
  • Your MCP connection URL copied from InstaWP dashboard

Configuration Steps

Step 1: Open your terminal or command prompt.

Step 2: Run the following command to add your InstaWP site as an MCP connection:

bash
claude mcp add --transport http mymcp <mcp_url>

Replace <mcp_url> with your actual MCP connection URL copied from the InstaWP dashboard.

Example:

bash
claude mcp add --transport http mymcp https://yoursite.instawp.io/insta-mcp?t=your-auth-token-here

Step 3: Claude Code will validate the connection and confirm it was added successfully.

| ✅ MCP Connection Added! Your WordPress site is now connected to Claude Code. You can start using Claude in your terminal to interact with your WordPress content.

Using Claude Code with Your Site

Once connected, you can use Claude Code in your terminal to interact with your WordPress site:

Start a conversation:

bash
claude

Example queries:

  • "Show me the latest posts from my WordPress site"
  • "Analyze my site structure"
  • "What plugins are installed on my site?"

Managing Connections

List all MCP connections:

bash
claude mcp list

Remove a connection:

bash
claude mcp remove mymcp

Note: The connection name "mymcp" in the command is a label you choose to identify this connection. You can use any name that helps you remember which site it connects to (e.g., "production-site", "client-blog", etc.).

Using MCP with Your Site

Once connected, you can manage your WordPress site through natural language conversations.

Things to Try

Content

  • "Show me my latest 5 blog posts"
  • "Create a draft 'Pricing' page with a hero, a three-column feature grid, and an FAQ"
  • "Find every post mentioning 'WordPress 6.8' and update the version to 7.0"
  • "Set the featured image on my last three posts from these URLs"

Site building

  • "Build me an About page using the site's theme colours"
  • "Edit the hero heading on my Elementor home page"
  • "Switch to Twenty Twenty-Five, verify the site still renders, and roll back if it breaks"

Store & custom fields

  • "Put every product in the Summer category on a 20% sale"
  • "Fill the ACF subtitle field on all Services pages"

Maintenance & diagnostics

  • "Why is my homepage throwing a 500?"
  • "Update all plugins one at a time and check the site still loads after each"
  • "Audit the site before launch — drafts, missing alt text, empty SEO meta"

Best Practices

  • Be specific: Name the page, post, or plugin you mean
  • Ask for a draft first: "Create it as a draft" gives you a review step before anything goes live
  • Ask it to verify: "…and check the page renders" makes the assistant confirm its own work
  • Use Safe Mode on sites that matter: it blocks delete operations entirely (see Permissions & Safe Mode)

What Your AI Assistant Can Do (Tool Reference)

InstaMCP exposes 43 tools. The 40 standard tools are available as soon as you connect; the 3 Capabilities tools are listed but inert until an admin enables them.

AreaToolsWhat it covers
Content (9)discover_content_types, list_content, get_content, get_content_by_slug, find_content_by_url, create_content, update_content, patch_content, delete_contentPosts, pages and custom post types. Large posts are fetched line-by-line, and patch_content does sed-style search-and-replace so long articles can be edited without resending the whole body.
Gutenberg blocks (2)discover_blocks, validate_blocksReads the blocks actually registered on your site and validates block markup before it's saved, so pages don't land with "this block contains unexpected or invalid content".
Custom fields / meta (2)get_meta, set_metaTyped writes routed through WooCommerce (WC_Product->save(), keeping the price lookup table in sync), ACF (update_field), or plain post meta — each value read back and reported as verified. Supports dry runs. Secret-looking values are redacted on read.
Taxonomies (9)discover_taxonomies, get_taxonomy, list_terms, get_term, create_term, update_term, delete_term, assign_terms_to_content, get_content_termsCategories, tags and custom taxonomies.
Plugins (3)plugin_info, plugin_operations, plugin_filesSearch wordpress.org, install, activate, update, delete, and read/write plugin files.
Themes (3)theme_info, theme_operations, theme_filesInstall, switch, update, delete themes and edit theme files.
Media (3)media_upload, media_attach, media_metadataUpload from a URL or base64, set featured images, and manage alt text, captions and descriptions.
Skills (4)skill_list, skill_get, skill_save, skill_deleteReusable playbooks the assistant consults when a task matches.
Memory (4)memory_save, memory_list, memory_get, memory_deleteDurable per-site facts.
Diagnostics (1)site_logsRead-only tail of the WordPress debug log and PHP error_log, filterable by level (fatal / error / warning / notice / deprecated) and search term, with secrets redacted. It does not read web access logs.
Capabilities (3, off by default)execute_php, db_query, site_filesPower tools an admin must switch on.

PHP file safety: theme_files, plugin_files and site_files syntax-check PHP before writing it and reject a write that wouldn't parse. execute_php snapshots every auto-included PHP file (theme functions.php, active plugin entry files, mu-plugins, drop-ins, wp-config.php) and automatically rolls back any file its run leaves broken — so a bad edit can't fatal your site and lock the assistant out.

WordPress Abilities API: on WordPress 6.9+, every InstaMCP tool is also registered via wp_register_ability(), so the official WordPress MCP Adapter and other Abilities-aware plugins can see and invoke them. On older WordPress versions this is a no-op and everything works as before.

Skills — Built-in Playbooks

Skills are reusable Markdown playbooks. When your request matches a skill's description, the assistant loads that playbook and follows it — so it gets multi-step jobs right the first time instead of improvising.

15 skills ship with InstaMCP:

SkillWhat it does
Build a Gutenberg pageBuilds showcase-grade pages from native Gutenberg blocks, validated before the first save
Build or edit a page-builder pageWorks Elementor and Bricks pages by writing the builder's own data and regenerating its CSS
Build, edit & resolve feedback on an InstaStudio siteHandles HTML-first "source-rendered" sites served by the InstaStudio plugin, including pin feedback
Build a site from a briefPopulates a new or staging site's pages, posts, terms and media from a content plan — draft-first
Bulk content operationsApplies the same change safely across many posts
Set product prices, ACF fields, and SEO metaTyped, dry-run-first, verified writes via set_meta
SEO meta + schema passAudits and improves titles, meta descriptions, slugs, and adds basic schema
Media + featured imagesUploads, alt text, and attaching/featuring images correctly
Tidy and reorganize taxonomiesMerges duplicates, renames, reassigns content, removes orphans
Manage 301/302 redirectsAdds or audits redirects after slug changes or a migration
Safe plugin updateCheck → update → verify the site still renders
Safely switch or test a themeInstall/switch with a render check and one-step rollback
Diagnose a slow or broken siteRead-only investigation: logs, active plugins/theme, root cause
Pre-launch / handoff content QAGo-live audit: drafts, broken internal links, missing alt/featured images, empty SEO meta
Create a SkillHow the assistant authors a new skill of your own

Managing skills

Skills are managed on your site in WP Admin → Settings → InstaMCP → Skills:

  • Disable any built-in skill you don't want offered
  • Allow (or block) agent-authored skills — when allowed, the assistant can save its own playbooks for your site (e.g. "remember how we build client landing pages") and reuse them later

InstaMCP Skills settings tab in WordPress admin, listing the built-in skills with enable checkboxes

Built-in skills are read live from the plugin, so a plugin update ships new and improved playbooks automatically.

Memory — What Your Assistant Remembers

Memory gives your assistant durable, per-site facts it can recall in a future conversation — site conventions, your preferences, project decisions, and reference pointers. Without it, every new chat starts from zero.

Useful things to tell it to remember:

  • "Remember that our brand colours are #0F62FE and #161616"
  • "Remember that all new posts go out under the 'Editorial' category and stay as drafts"
  • "Remember the client prefers Bricks, not Elementor"

Memory is stored on your own site, scoped to that site only, and you can ask the assistant to list, read, or delete entries at any time.

Capabilities — Power Tools (Off by Default)

Three tools give an assistant deep access. They're always listed over MCP so an assistant can discover them and tell you how to enable them — but each is off by default and returns a "here's how to enable me" error until an admin turns it on. All three require an administrator token, and their write operations are additionally blocked by Safe Mode.

Turn them on in WP Admin → Settings → InstaMCP → Capabilities:

InstaMCP Capabilities settings tab showing Execute PHP, Database Query and Site Files, all off by default

ToolModesWhat it does
Execute PHP (execute_php)Off / OnRuns arbitrary PHP in full WordPress context. Hard 30-second limit per call; returns the return value, output and warnings. Broken auto-included files are automatically rolled back.
Database Query (db_query)Off / Read-only / Read & writeRuns a single SQL statement. Read-only allows SELECT/SHOW/DESCRIBE/EXPLAIN (bare SELECTs get an automatic LIMIT); read & write also allows INSERT/UPDATE/DELETE/DDL. Multi-statements, file I/O (LOAD DATA, LOAD_FILE, INTO OUTFILE) and SLEEP/BENCHMARK are blocked in both modes.
Site Files (site_files)Off / Read-only / Read & writeRead, list and write WordPress config and drop-in files via a strict allowlist: wp-config.php, .htaccess, wp-content/mu-plugins/**, the drop-ins (object-cache.php, advanced-cache.php, db.php, maintenance.php) and wp-content/uploads/**. Writes create a timestamped backup and honour DISALLOW_FILE_EDIT/DISALLOW_FILE_MODS; wp-config.php secrets are redacted on read.

⚠️ Enable with care. execute_php — and site_files in read & write mode, which can drop an executable mu-plugin — give the connected assistant root-equivalent control over WordPress. Enable them on sandbox, staging and development sites, or when you fully trust the client you've connected. Leave them off on production.

Prefer to enable them from the command line? Use the web terminal or SSH:

bash
wp option update insta_mcp_execute_php_enabled 1
wp option update insta_mcp_db_query_mode read       # off | read | read_write
wp option update insta_mcp_site_files_mode read     # off | read | read_write

Permissions & Safe Mode

Your MCP connection URL carries a token tied to a WordPress user, and it inherits exactly that user's role and capabilities. There is no way for MCP to do something the underlying user couldn't do in wp-admin.

WordPress rolePermission scopesWhat it can do
Administratormcp:admin, mcp:delete, mcp:write, mcp:readEverything, including the Capabilities tools once enabled
Editormcp:delete, mcp:write, mcp:readEdit and publish any content
Authormcp:write, mcp:readCreate and publish their own content only
Contributormcp:readCreate drafts
Subscribermcp:readRead-only

Two extra controls live in WP Admin → Settings → InstaMCP:

  • Safe Mode (General tab) — blocks all delete operations, and gates the write side of the Capabilities tools. A good default for any site you care about.
  • API Tokens tab — create additional tokens (optionally for a different, lower-privileged WordPress user, with an expiry), see when each was last used, and revoke any of them. Giving an assistant an Editor or Author token is the simplest way to limit what it can reach.

How to Disable MCP

If you want to disable MCP and disconnect AI access to your site:

Step 1: Go to your Sites page and click the ellipsis button next to your site.

Step 2: Select MCP from the menu.

Step 3: Toggle the Enable MCP switch to OFF.

Step 4: InstaWP will automatically:

  • Deactivate the MCP WordPress plugin
  • Remove the plugin from your site
  • Invalidate your connection token

| 🔒 Security: Once disabled, the previous connection URL will no longer work. Claude Desktop will lose access to your site immediately. If you enable MCP again, a new connection URL with a different token will be generated.

Step 5: (Optional) Remove the connector from your AI assistant:

For Claude Desktop:

  • Go to Settings > Connectors
  • Find your WordPress site connector
  • Click "Remove" or "Delete"

For Claude Code:

  • Run: claude mcp remove mymcp

Troubleshooting

Connection Issues

Problem: Claude Desktop shows "Connection Failed" or cannot connect to my site.

Solutions:

  • Verify that MCP is enabled in your InstaWP dashboard
  • Ensure you copied the complete connection URL, including the token parameter
  • Check that your site is active and not suspended
  • Try regenerating the connection by disabling and re-enabling MCP

Problem: Claude Desktop says it cannot access my site content.

Solutions:

  • Verify the connection status in Claude Desktop Settings > Connectors
  • Make sure your site is accessible (not in maintenance mode)
  • Try reconnecting by removing and re-adding the connector in Claude Desktop
  • Check that the MCP plugin is active on your WordPress site

Problem: Claude Code shows an error when adding the MCP connection.

Solutions:

  • Verify you copied the complete connection URL with the authentication token
  • Check that Claude Code CLI is properly installed and up to date
  • Ensure the URL is properly quoted if it contains special characters
  • Try the command with the full URL in quotes: claude mcp add --transport http mymcp "https://..."

Access Level Issues

Problem: Claude Desktop has limited access or cannot perform certain actions.

Solution:

  • Check the role of the WordPress user your token belongs to — an Author token can only edit its own posts (see Permissions & Safe Mode)
  • If deletes are failing, Safe Mode is probably on (WP Admin → Settings → InstaMCP → General)
  • If the assistant reports that execute_php, db_query or site_files is disabled, that's expected — enable it under Capabilities

Problem: The connection URL returns my site's homepage HTML instead of connecting.

Solutions:

  • This can happen right after an InstaMCP plugin update if rewrite rules were dropped. Update to the latest InstaMCP version (WP Admin → Plugins → Check for Updates), which re-flushes them automatically
  • As an immediate fix, re-save your permalinks (WP Admin → Settings → Permalinks → Save Changes)

Token or URL Issues

Problem: My connection URL doesn't work after some time.

Solutions:

  • Connection URLs are invalidated when you disable MCP
  • If you suspect the token is compromised, disable and re-enable MCP to generate a new token
  • Do not share your connection URL publicly

FAQs

Can I connect multiple AI assistants to the same site?

Yes. The connection URL shown in the InstaWP dashboard can be reused across multiple clients, and you can also create additional tokens under WP Admin → Settings → InstaMCP → API Tokens — one per client, each with its own label, optional expiry, and its own WordPress user. That way you can revoke one assistant's access without disconnecting the others.


Does enabling MCP affect my site's performance?

No, MCP installs a lightweight WordPress plugin that only responds when accessed through the MCP protocol. It does not impact your regular site visitors or site performance.


Can I use MCP with non-InstaWP WordPress sites?

MCP is currently designed specifically for InstaWP sites. The feature requires InstaWP's infrastructure to install and configure the MCP plugin automatically.


What data can Claude Desktop access through MCP?

Whatever the WordPress user behind your token can access: posts, pages and custom post types, taxonomies, media, custom fields, plugin and theme information and files, and the WordPress error logs. Passwords are never exposed (WordPress stores them hashed), and values that look like secrets — tokens, API keys, wp-config.php credentials — are redacted by default.

Direct database access (db_query) and config-file access (site_files) are off unless an administrator enables them under Capabilities.


Can the assistant edit my theme or install plugins?

Yes, with an administrator token: it can install, activate, update and delete plugins and themes, and read/write their files. PHP is syntax-checked before it's written, so a bad edit is rejected rather than saved. Enable Safe Mode if you want deletes blocked.


What are Skills, and do I have to set them up?

No setup needed — 15 built-in Skills ship with the plugin and the assistant picks the right one automatically. You can disable any of them, and allow the assistant to save its own, under WP Admin → Settings → InstaMCP → Skills.


Does the assistant remember things between conversations?

Yes — Memory stores durable facts on your site (conventions, preferences, decisions) that it can recall in a later chat. Ask it to list or delete entries any time.


Will my MCP connection work if I migrate my site?

If you migrate your site to a different hosting provider or domain, you will need to disable and re-enable MCP to generate a new connection URL for the new location.


Is there a limit to how many requests Claude can make to my site?

There are no specific rate limits mentioned for MCP connections, but excessive API requests may be subject to standard WordPress API rate limiting or InstaWP's fair use policies.


Can I restrict what Claude Desktop can do with my site?

Yes, three ways, and they stack:

  1. Issue a lower-privileged token — create a token for an Editor, Author or Contributor user under WP Admin → Settings → InstaMCP → API Tokens (optionally with an expiry date)
  2. Turn on Safe Mode — blocks all delete operations
  3. Leave Capabilities offexecute_php, db_query and site_files are disabled unless you enable them

See Permissions & Safe Mode.


Can I use both Claude Desktop and Claude Code with the same site?

Yes! You can connect the same InstaWP site to both Claude Desktop and Claude Code using the same MCP connection URL. Both will have the same level of access to your WordPress content.


| 💡 Did you know - You can also access your site files using SFTP/SSH for manual file management. Learn about SFTP/SSH.


Docs are open — edit on GitHub. Built with VitePress.