trackmcp
Back to directory
5unnykum4r

wordpress-mcp

View on GitHub

A Model Context Protocol (MCP) server that gives AI agents full control over WordPress sites. 46 tools for posts, pages, media, SEO, comments, redirects, blocks, patterns, TablePress, and more.

1 stars PHPOthers Updated Aug 17, 2026

Documentation

WordPress MCP

A Model Context Protocol (MCP) server that gives AI agents full control over WordPress sites. Manage posts, pages, media, categories, tags, comments, SEO, redirects, Gutenberg blocks, reusable patterns, TablePress tables, plugins, users, and site settings — all through 46 MCP tools.

Built for Claude Code. Also compatible with the Claude Agent SDK and any MCP-capable client.

How It Works

code
┌─────────────┐     JSON-RPC      ┌──────────────────┐     HTTP/Auth     ┌─────────────────┐
│  Claude /    │ ──────────────▶  │  Python MCP      │ ──────────────▶  │  WordPress Site  │
│  AI Agent    │                  │  Proxy Server    │                  │  (MCP Adapter)   │
│              │ ◀──────────────  │  (server.py)     │ ◀──────────────  │  (mu-plugin)     │
└─────────────┘     MCP Tools     └──────────────────┘     JSON-RPC     └─────────────────┘
                                         │
                                    sites.json
                                  (multi-site config)

A single Python proxy handles unlimited WordPress sites. Each tool call includes a `site` parameter to target a specific site. Authentication uses WordPress Application Passwords (built into WP 5.6+).

Features

CategoryToolsCapabilities
Posts & Pages9 toolsCRUD, bulk status change, revisions, search & replace
Categories & Tags8 toolsCRUD with Rank Math SEO support
Media4 toolsUpload from URL, browse library, update metadata, delete
Comments3 toolsList, moderate (approve/spam/trash), reply, delete
Rank Math SEOFull SEO metadata on posts and categories (title, description, focus keyword, Open Graph, Twitter, schema, robots)
Redirections4 toolsRank Math redirect CRUD (301/302/307/410/451)
Gutenberg Blocks1 toolDiscover all registered block types with attribute schemas
Synced Patterns5 toolsCreate, read, update, delete reusable blocks
TablePress5 toolsFull table CRUD with display options and visibility
Plugins2 toolsList installed plugins, activate/deactivate
Users1 toolList users with role filtering
Settings3 toolsRead/write options, flush caches, get site info
Utility1 toolList all configured sites

Total: 46 tools covering the full WordPress management surface.

Quick Start

1. Install the WordPress adapter

bash
# Build PHP dependencies locally
cd wordpress/
composer install

# Upload vendor/ and load-mcp-adapter.php to your WordPress server
# See SETUP.md for detailed instructions

2. Configure the proxy

bash
# Copy the example config
cp sites.json.example sites.json

# Edit with your site details
json
{
  "myblog": {
    "url": "https://yourdomain.com/wp-json/mcp/mcp-adapter-default-server",
    "username": "YourAdmin",
    "password": "xxxx xxxx xxxx xxxx xxxx xxxx"
  }
}

3. Connect to Claude

Claude Code — add to `~/.claude.json` (or ask your Claude Code agent to set it up for you):

json
{
  "mcpServers": {
    "wordpress": {
      "type": "stdio",
      "command": "uv",
      "args": [
        "run",
        "--with", "fastmcp",
        "--with", "httpx",
        "python",
        "/path/to/wordpress-mcp/server.py"
      ]
    }
  }
}

Then install the skill for tool documentation:

bash
npx skills add 5unnykum4r/wordpress-mcp

Or manually symlink:

bash
ln -s /path/to/wordpress-mcp/skill/wordpress-mcp ~/.claude/skills/wordpress-mcp

See the full setup guide for detailed instructions, troubleshooting, and usage examples.

Tool Reference

All tools require `site` as the first parameter.

Posts & Pages (9 tools)

ToolAction
`list_posts`List/filter posts and pages
`read_post`Read full content, metadata, SEO
`create_post`Create with content, categories, tags, SEO
`update_post`Partial update any fields
`delete_post`Trash or permanently delete
`bulk_update_status`Change status of multiple posts
`list_revisions`View revision history
`restore_revision`Revert to a previous revision
`search_replace`Find/replace across content (dry run supported)

Categories & Tags (8 tools)

ToolAction
`list_categories`List with Rank Math SEO data
`create_category`Create with optional SEO
`update_category`Update name, slug, parent, SEO
`delete_category`Delete (posts move to default)
`list_tags`List and search tags
`create_tag`Create a new tag
`update_tag`Update tag name, slug, description
`delete_tag`Remove a tag (posts are untagged)

Media (4 tools)

ToolAction
`upload_image`Download from URL and add to media library
`list_media`Browse with mime type filtering
`update_media`Update title, alt text, caption
`delete_media`Permanently delete

Comments (3 tools)

ToolAction
`list_comments`Filter by post, status, search
`update_comment`Approve, spam, trash, or reply
`delete_comment`Permanently delete

Redirections (4 tools)

ToolAction
`list_redirections`List Rank Math redirects
`create_redirection`Create 301/302/307/410/451 redirect
`update_redirection`Modify source, destination, type
`delete_redirection`Remove a redirect rule

Gutenberg & Patterns (6 tools)

ToolAction
`list_block_types`Discover registered blocks + schemas
`list_patterns`List reusable/synced patterns
`read_pattern`Read pattern block content
`create_pattern`Create synced pattern
`update_pattern`Update pattern content
`delete_pattern`Delete a pattern

TablePress (5 tools)

ToolAction
`list_tablepress_tables`List all tables
`read_tablepress_table`Read data, options, visibility
`create_tablepress_table`Create with 2D data array
`update_tablepress_table`Update data, options, visibility
`delete_tablepress_table`Permanently delete

Administration (7 tools)

ToolAction
`list_plugins`List installed plugins + status
`toggle_plugin`Activate or deactivate
`list_users`List users by role
`manage_options`Read/write WordPress settings
`clear_cache`Flush all caches
`get_info`Site info, versions, theme
`list_sites`Show configured sites

Project Structure

code
wordpress-mcp/
├── README.md                  ← This file
├── SETUP.md                   ← Full setup guide + troubleshooting
├── LICENSE                    ← MIT license
├── server.py                  ← Python MCP proxy (FastMCP + httpx)
├── sites.json.example         ← Site configuration template
├── wordpress/
│   ├── load-mcp-adapter.php   ← WordPress MU-plugin (server-side)
│   ├── composer.json          ← PHP dependencies
│   └── composer.lock
└── skill/
    └── wordpress-mcp/         ← Claude Code skill
        ├── SKILL.md
        └── references/        ← Tool documentation (7 files)

Requirements

Local (proxy server):

  • Python 3.10+
  • uv package manager
  • FastMCP and httpx (installed automatically by `uv run`)

WordPress server:

  • WordPress 5.6+ (for Application Passwords)
  • PHP 7.4+
  • Composer packages: `wordpress/abilities-api` and `wordpress/mcp-adapter`

Multi-Site Management

Add as many WordPress sites as you need to `sites.json`:

json
{
  "blog": {
    "url": "https://blog.example.com/wp-json/mcp/mcp-adapter-default-server",
    "username": "admin",
    "password": "xxxx xxxx xxxx xxxx xxxx xxxx"
  },
  "shop": {
    "url": "https://shop.example.com/wp-json/mcp/mcp-adapter-default-server",
    "username": "admin",
    "password": "yyyy yyyy yyyy yyyy yyyy yyyy"
  },
  "docs": {
    "url": "https://docs.example.com/wp-json/mcp/mcp-adapter-default-server",
    "username": "editor",
    "password": "zzzz zzzz zzzz zzzz zzzz zzzz"
  }
}

Each site gets its own alias. Target any site with `site="blog"`, `site="shop"`, etc. No proxy restart needed when adding new sites.

Contributing

Contributions are welcome. Please open an issue or pull request.

License

MIT

Frequently asked questions

What is wordpress-mcp?

wordpress-mcp is A Model Context Protocol (MCP) server that gives AI agents full control over WordPress sites. 46 tools for posts, pages, media, SEO, comments, redirects, blocks, patterns, TablePress, and more.

How do I install wordpress-mcp?

Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.

Is wordpress-mcp open source?

Yes — it is hosted on GitHub at https://github.com/5unnykum4r/wordpress-mcp and has 1 stars.

Related MCP tools

Run your own MCP server? See who uses it and what to fix.

Measure it with TrackMCP