WordPress MCP server setup diagram showing Claude Code connected to a WordPress blog

Want your AI coding assistant to manage your blog directly? No more one-off scripts or manual copy-pasting. Setting up a WordPress MCP server lets Claude Code discover and call WordPress functionality through a standardized protocol. That includes posts, pages, media, comments, and more. This guide walks through installing the two plugins that make this possible. It also covers wiring up the connection from your local Claude Code setup.

  1. Download the mcp-adapter plugin from the releases page (go to the tag you want).

    What is mcp-adapter? It’s an official WordPress plugin that bridges WordPress’s “Abilities API” with the Model Context Protocol (MCP). This lets AI agents such as Claude discover and invoke WordPress functionality through a standardized protocol. wp_register_ability() automatically surfaces registered abilities as MCP-compatible tools, resources, and prompts. That applies whether they come from core, themes, or plugins, and any MCP-aware client can consume them.

    Why it’s needed: without it, there’s no standard way for an AI agent to discover or call WordPress functionality. Every integration would otherwise need bespoke, site-specific glue code. The adapter exposes a JSON-RPC MCP server endpoint and handles protocol negotiation. It also handles authentication (WordPress Application Passwords for remote HTTP, or WP-CLI for STDIO), schema validation, and error handling.

    Capabilities: supports both HTTP (per the MCP spec) and STDIO transports, plus a custom transport interface. Rather than exposing every ability as its own tool, the default server exposes three meta-tools: mcp-adapter/discover-abilities, mcp-adapter/get-ability-info, and mcp-adapter/execute-ability. Plugin authors can also register their own abilities. They can even run multiple independent MCP servers with distinct settings and observability hooks. Requires PHP 7.4+ and WordPress 6.9+.

    In short, this plugin is what turns your site into a WordPress MCP server. Any MCP-aware client, including Claude Code, can then connect to it.

  2. On the WordPress admin panel, add the plugin from the filesystem and activate it.

  3. Search for the Enable Abilities for MCP plugin on the admin panel, install it, and activate it.

    What it does: mcp-adapter is purely a protocol bridge — it ships with no default abilities of its own. So an MCP client connecting through it would find an empty tool set. “Enable Abilities for MCP” fills that gap by registering a concrete library of WordPress actions (“abilities”). It covers up to 71 abilities across 16 categories. The adapter can then expose these as callable MCP tools.

    Capabilities: it covers the full content-management lifecycle — posts, pages, media, taxonomies, custom post types, and site metadata like post counts. It also offers optional integrations with WooCommerce, Yoast/Rank Math/SEOPress, Polylang/WPML, The Events Calendar, and LearnDash. Each ability enforces normal WordPress capability checks, and you can toggle individual abilities on/off from Settings > WP Abilities.

    Why we need it here: this is what actually gives Claude something to call. Without it, mcp-adapter has nothing to expose, so a connected MCP client couldn’t do anything useful — like counting published posts.

  4. Add this config to your ~/.claude.json file, replacing <your-site-url>, <your-username>, and <your-app-password> with your own values:

    {
      "mcpServers": {
        "wp-blog-<your-site-name>": {
          "type": "stdio",
          "command": "npx",
          "args": [
            "-y",
            "@automattic/mcp-wordpress-remote@latest"
          ],
          "env": {
            "WP_API_URL": "https://<your-site-url>/wp-json/mcp/mcp-adapter-default-server",
            "WP_API_USERNAME": "<your-username>",
            "WP_API_PASSWORD": "<your-app-password>",
            "OAUTH_ENABLED": "false"
          }
        }
      }
    }
    

    Where to get these values:

    • WP_API_URL is your WordPress site’s MCP adapter REST endpoint: https://<your-site-url>/wp-json/mcp/mcp-adapter-default-server.
    • WP_API_USERNAME is your WordPress login username (not your email) — the account should have Administrator or Editor permissions.
    • WP_API_PASSWORD is a WordPress Application Password — a 24-character credential separate from your normal login password. Generate one at wp-admin → Users → Profile → Application Passwords. Enter a descriptive name (e.g. “MCP Server”) and click “Add New Application Password”. WordPress shows the generated key once — you can include spaces or not, since WordPress strips them automatically. Copy it immediately, since you can’t retrieve it again. You can always revoke it and generate a new one. You must serve your site over HTTPS, since WordPress disables application passwords over plain HTTP by default.
  5. Verify your WordPress MCP server by running claude, then /mcp, and asking it to connect.

  6. Try out the connection with a prompt, for example: “Get me the count of published posts on this blog.”

Related reading: once your WordPress MCP server is up, you’ll likely start running longer Claude Code sessions to manage your blog. Then you’ll want to know the moment a task finishes or needs a permission decision. See Never Miss a Finished Claude Task: Desktop Notifications for Claude Code in iTerm2 for how to set that up.

Leave a Reply

Your email address will not be published. Required fields are marked *