Connect Claude Code to WordPress over MCP
Point Claude Code at your site's MCP endpoint as a scoped user. Connect once, then it can call only the abilities you switched on, and every call is checked and logged.
Set it up in four steps
The same path works for Claude Code as for every MCP client. The exact wording of a menu or field may differ in your version, but the flow is the same.
-
Turn on what you want
Open the Agent Abilities for MCP screen and enable only the abilities you want the agent to have. Everything starts off.
-
Copy your endpoint
On the Connection tab, copy your site’s MCP endpoint.
-
Connect your AI client
The simplest path is OAuth: paste the endpoint into your client and approve once in the browser. Or point a dedicated low-privilege user at an Application Password.
-
Check the connection
Use the connection check on the Connection tab to confirm the endpoint is reachable from your server.
Two ways to connect. Both least privilege.
Claude Code authenticates as a real WordPress user you pick, never an admin-equivalent key. Choose the method that fits how you work.
Approve once in the browser
Approve the agent once in the browser. No secret to store; the agent acts as your own account.
Bind a low-privilege user
Point a dedicated low-privilege user at the endpoint. A guided screen builds the client config and checks the endpoint for you.
Same steps, two operating systems
OAuth is identical everywhere: paste the endpoint and approve in the browser. The only real difference is the local bridge on Windows, which needs a small wrapper. The plugin's Connection tab has a Windows tab that writes this for you.
macOS / Linux
Paste your MCP endpoint into your client and approve once over OAuth, or run the mcp-remote bridge as-is. No special wrapping needed.
Windows
OAuth works the same: paste the endpoint and approve in the browser. If a client uses the mcp-remote bridge, Windows cannot launch the npx shim by name, so wrap it in cmd: set command to cmd and put /c, npx at the front of args. The plugin’s Connection tab has a Windows tab that generates this exact config for you.
{
"mcpServers": {
"wordpress": {
"url": "https://your-site.com/wp-json/…/mcp"
}
}
} An illustrative shape only. The URL above is a placeholder, not a working endpoint. Copy your real endpoint from the plugin's Connection tab, which also generates the exact config for your client.
The bridge: Clients that cannot open a remote MCP connection use the open-source mcp-remote bridge, which runs on your own machine.
Where to get your real endpoint and token: open Agent Abilities for MCP in wp-admin, go to the Connection tab, and copy the endpoint there. The same screen builds the client config for you and runs a connection check so you can confirm the endpoint is reachable before you connect Claude Code.
If the connection will not start
A few common snags and their fixes. These apply to MCP setup generally, not just Claude Code.
OAuth discovery returns 403 or 404
Some servers deny anything that starts with a dot before PHP runs, which blocks the /.well-known/ documents MCP clients need. On nginx, add a location block so /.well-known/ falls through to WordPress.
A Windows client will not start
Windows MCP clients cannot launch the npx shim by name. Wrap it in cmd: set command to cmd and put /c, npx at the front of args. The Connection tab generates this for you.
Cannot connect to a local or staging site
Local stacks serve a self-signed certificate that Node rejects. For local testing only, add NODE_TLS_REJECT_UNAUTHORIZED 0 to the env block. Never ship that to production.
Governed by default, from the first call.
Install the plugin, connect Claude Code as a scoped user, and enable one ability at a time. Requires WordPress 6.9+ and PHP 8.0+. Free on WordPress.org, no paid tier, no API key to buy, no usage limits.
Governed from the first call. Nothing leaves your site without you.