# I Connected My AI Agent to WordPress via MCP — And You Can Too (No Coding Needed)

- Link: https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/
- Published: 2026-10-17T23:10:52+03:00
- Author: eJohnny

## The Hidden Bridge Between AI Agents and Your Blog

Most people think AI agents like Claude Desktop, Cursor, or OpenCode can only talk
to you. They don’t realize these agents can become direct editors, writers, and 
publishers for their WordPress site — securely, without sharing passwords over email
or building custom plugins.

In this tutorial, I will show you exactly how I connected my OpenCode agent (running
on a VPS) to my shared-hosted WordPress blog at `dev.ejohnny.ro` using the official**
WordPress MCP Adapter**. It took less than 10 minutes, required zero custom code
on my site, and now my AI can discover abilities, query content, and publish articles
directly.

## What Is the WordPress MCP Adapter?

The adapter is an official plugin from the WordPress Core AI team. It takes the **
Abilities API** (introduced in WordPress 6.9) and exposes it through the [Model Context Protocol (MCP)](https://modelcontextprotocol.io/).
That means any MCP-compatible AI client — Claude Desktop, VS Code, Cursor, Claude
Code, or OpenCode — can discover what your site can do and call it as a tool.

## What We Actually Did (Step-by-Step)

 1. **Installed the adapter plugin** on `dev.ejohnny.ro` via the plugin directory or
    GitHub releases (`mcp-adapter` v0.7.1).
 2. **Created an application password** for it in WP Admin.
 3. **Saved credentials locally** in opencode.
 4. **Tested authentication** via the REST API (`/wp-json/wp/v2/users/me`) — it worked
    instantly.
 5. **Verified the Abilities API** was exposed (`/wp-json/wp-abilities/v1/abilities`).
 6. **Used the adapter’s default server** to make my AI agent discover site info, user
    info, and environment data.
 7. **Deleted a draft post directly** through the API — clean, fast, and traceable.

## The Real Perks (Why This Changes Everything)

 * **Zero custom plugins needed** — the adapter handles MCP transport for you.
 * **Works across clients** — Claude Desktop, Cursor, VS Code, Claude Code, and 
   OpenCode all speak MCP.
 * **Read and write access is granular** — abilities declare their permissions, 
   so destructive actions are gated.
 * **Works on shared hosting** — no SSH, no WP-CLI required; the HTTP transport 
   connects over the public web.
 * **Discoverable by design** — the agent asks what abilities exist before acting.
   No hardcoded endpoints.

## What Can You Actually Use This For?

Once connected, your AI agent can:

 * Query site info, user profiles, and environment details.
 * List, read, update, or create posts and pages.
 * Discover plugin or theme capabilities registered as abilities.
 * Run custom abilities from your own plugins via a custom MCP server.
 * Automate editorial workflows — draft, review, and publish — without leaving your
   AI workspace.

## How to Replicate This (Quick Checklist)

If you want your own AI-to-WordPress bridge:

 1. Install the [MCP Adapter plugin](https://github.com/WordPress/mcp-adapter).
 2. Create an [application password](https://make.wordpress.org/core/2020/11/05/application-passwords-integration-guide/).
 3. Set up the remote proxy (`@automattic/mcp-wordpress-remote`) or use STDIO if you
    have WP-CLI locally.
 4. Add the MCP server config to your AI client’s settings (`.claude.json`, `mcp.json`,
    etc.).
 5. Start using abilities as natural-language commands: _“Get site info from my WordPress
    site”_.

## The Bottom Line

The gap between AI agents and content management systems just collapsed. The WordPress
MCP Adapter turns any WordPress site into an AI-ready API without exposing your 
admin dashboard or writing custom integrations. Whether you are a blogger, developer,
or content team, this is the simplest and most secure way to give AI real access
to your site.

_Note: Always use dedicated users with limited capabilities for MCP access, prefer
read-only abilities for public endpoints, and monitor usage via custom logging._

### Share this:

 * [  X ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=twitter)
 * [  Facebook ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=facebook)
 * [More](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/#)

 * [  LinkedIn ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=linkedin)
 * [  Reddit ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=reddit)
 * [  Tumblr ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=tumblr)
 * [  Pinterest ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=pinterest)
 * [  Telegram ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=telegram)
 * [  WhatsApp ](https://dev.ejohnny.ro/opencode-wordpress-mcp-adapter-tutorial/?share=jetpack-whatsapp)
