WordPress MCP Server
The WordPress MCP Server enables programmatic interaction with WordPress sites via the REST API. Key capabilities include:
Content Management: Create, retrieve, update, and delete posts with advanced filtering and pagination
User Administration: Manage users including creation, retrieval (by ID/login), updating, deletion, and filtering by roles/capabilities
Comment Handling: Retrieve and create comments with filtering options
Taxonomy Management: Create, update, retrieve, and delete categories and tags
Site Statistics: Access comprehensive stats on views, visitors, likes, comments, top posts, country views, and publishing streaks
Spam Control: Report and remove referrer spam
Analytics: Track outbound clicks and search terms used to find the site
Custom Functionality: Make custom requests to any WordPress REST API endpoint with support for different HTTP methods and parameters
Enables interaction with WordPress sites through the WordPress REST API, providing tools for managing posts, users, comments, categories, tags, and custom endpoints. Supports creating, retrieving, updating, and deleting WordPress content programmatically.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@WordPress MCP Server create a draft post titled 'Weekly Update' with content 'Here's what happened this week'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Comprehensive WordPress MCP Server
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with WordPress sites through the WordPress REST API. This server provides tools for managing all aspects of WordPress programmatically, including posts, users, comments, categories, tags, and custom endpoints.
Features
Post Management
Create, retrieve, update, and delete WordPress posts
Filter posts by various parameters
Pagination support for post listings
User Management
Retrieve user information by ID or login
Update user details
Delete users
Comments Management
Create, retrieve, update, and delete comments
Filter comments by post
Pagination support for comment listings
Taxonomy Management
Manage categories and tags
Create, retrieve, update, and delete taxonomies
Find categories and tags by slug
Site Information
Retrieve general WordPress site information
Custom Requests
Support for custom REST API endpoints
Custom HTTP methods (GET, POST, PUT, DELETE)
Custom data and parameters
Related MCP server: WordPress MCP Server
Prerequisites
Node.js v18 or higher
A WordPress site with REST API enabled
WordPress application password for authentication
Installation
Clone this repository:
git clone [repository-url]
cd wordpress-mcp-serverInstall dependencies:
npm installBuild the server:
npm run buildWordPress Configuration
Before using the server, you need to set up your WordPress site:
Ensure your WordPress site has REST API enabled (enabled by default in WordPress 4.7+)
Create an application password:
Log in to your WordPress admin panel
Go to Users → Profile
Scroll down to "Application Passwords"
Enter a name for the application (e.g., "MCP Server")
Click "Add New Application Password"
Copy the generated password (you won't be able to see it again)
MCP Configuration
Add the server to your MCP settings file (usually located at ~/AppData/Roaming/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json):
{
"mcpServers": {
"wordpress": {
"command": "node",
"args": ["path/to/wordpress-mcp-server/build/index.js"]
}
}
}Available Tools
Post Management
1. create_post
Creates a new WordPress post.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordtitle(required): Post titlecontent(required): Post contentstatus(optional): Post status ('draft', 'publish', or 'private', defaults to 'draft')
Example:
{
"tool": "create_post",
"siteUrl": "https://example.com",
"username": "admin",
"password": "xxxx xxxx xxxx xxxx",
"title": "My First Post",
"content": "Hello, world!",
"status": "draft"
}2. get_posts
Retrieves WordPress posts with pagination.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordperPage(optional): Number of posts per page (default: 10)page(optional): Page number (default: 1)customParams(optional): Additional query parameters
Example:
{
"tool": "get_posts",
"siteUrl": "https://example.com",
"username": "admin",
"password": "xxxx xxxx xxxx xxxx",
"perPage": 5,
"page": 1
}3. update_post
Updates an existing WordPress post.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordpostId(required): ID of the post to updatetitle(optional): New post titlecontent(optional): New post contentstatus(optional): New post status ('draft', 'publish', or 'private')
Example:
{
"tool": "update_post",
"siteUrl": "https://example.com",
"username": "admin",
"password": "xxxx xxxx xxxx xxxx",
"postId": 123,
"title": "Updated Title",
"content": "Updated content",
"status": "publish"
}4. delete_post
Deletes a WordPress post.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordpostId(required): ID of the post to delete
Example:
{
"tool": "delete_post",
"siteUrl": "https://example.com",
"username": "admin",
"password": "xxxx xxxx xxxx xxxx",
"postId": 123
}User Management
1. get_users
Retrieves WordPress users.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordperPage(optional): Number of users per page (default: 10)page(optional): Page number (default: 1)
2. get_user
Retrieves a specific WordPress user by ID.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passworduserId(required): ID of the user to retrieve
3. get_user_by_login
Retrieves a WordPress user by login name.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passworduserLogin(required): Login name of the user to retrieve
Comment Management
1. get_comments
Retrieves WordPress comments.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordperPage(optional): Number of comments per page (default: 10)page(optional): Page number (default: 1)postIdForComment(optional): Filter comments by post ID
2. create_comment
Creates a new comment on a post.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordpostIdForComment(required): ID of the post to comment oncommentContent(required): Content of the commentcustomData(optional): Additional comment data
Category and Tag Management
1. get_categories
Retrieves WordPress categories.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordperPage(optional): Number of categories per page (default: 10)page(optional): Page number (default: 1)
2. create_category
Creates a new WordPress category.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordcategoryName(required): Name of the category to createcustomData(optional): Additional category data (description, parent, etc.)
Custom Requests
1. custom_request
Makes a custom request to any WordPress REST API endpoint.
Parameters:
siteUrl(required): Your WordPress site URLusername(required): WordPress usernamepassword(required): WordPress application passwordcustomEndpoint(required): API endpoint pathcustomMethod(optional): HTTP method ('GET', 'POST', 'PUT', 'DELETE', default: 'GET')customData(optional): Data for POST/PUT requestscustomParams(optional): URL parameters for GET requests
Example:
{
"tool": "custom_request",
"siteUrl": "https://example.com",
"username": "admin",
"password": "xxxx xxxx xxxx xxxx",
"customEndpoint": "wp/v2/media",
"customMethod": "GET",
"customParams": {
"per_page": 5
}
}Response Format
All tools return responses in the following format:
Success Response
{
"success": true,
"data": {
// WordPress API response data
},
"meta": {
// Optional metadata (pagination info, etc.)
}
}Error Response
{
"success": false,
"error": "Error message here"
}Security Considerations
Always use HTTPS URLs for your WordPress site
Use application passwords instead of your main WordPress password
Keep your application passwords secure and don't share them
Consider using WordPress roles and capabilities to limit access
Regularly rotate application passwords
Development
To contribute to the development:
Fork the repository
Create a feature branch
Make your changes
Run tests (when available)
Submit a pull request
For development mode with automatic recompilation:
npm run devLicense
This project is licensed under the ISC License.
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Available Tools
29 toolscreate-categoryC
Create a new WordPress category
Inputs: name (required), password (required), siteUrl (required), username (required), +4 more.
create-commentC
Create a new comment on a WordPress post
Inputs: content (required), password (required), postId (required), siteUrl (required), +3 more.
create-postC
Create a new WordPress post
Inputs: content (required), password (required), siteUrl (required), title (required), +17 more.
create-userC
Create a new WordPress user
Inputs: email (required), newPassword (required), newUsername (required), password (required), +11 more.
delete-categoryC
Delete a WordPress category
Inputs: categoryId (required), password (required), siteUrl (required), username (required), +1 more.
delete-postC
Delete a WordPress post
Inputs: password (required), postId (required), siteUrl (required), username (required), +1 more.
delete-userC
Delete a WordPress user
Inputs: password (required), reassignId (required), siteUrl (required), userId (required), +1 more.
get-categoryC
Get a specific category by ID
Inputs: categoryId (required), password (required), siteUrl (required), username (required), +1 more.
get-clicksC
View a site's outbound clicks
Inputs: password (required), siteId (required), siteUrl (required), username (required), +2 more.
get-commentsC
Get a list of comments from a WordPress site
Inputs: password (required), siteUrl (required), username (required), page, +2 more.
get-country-viewsC
View a site's views by country
Inputs: password (required), siteId (required), siteUrl (required), username (required), +2 more.
get-postC
Get a specific post by ID
Inputs: password (required), postId (required), siteUrl (required), username (required), +2 more.
get-post-statsC
View a specific post's views
Inputs: password (required), postId (required), siteId (required), siteUrl (required), +1 more.
get-referrersC
View a site's referrers
Inputs: password (required), siteId (required), siteUrl (required), username (required), +2 more.
get-search-termsB
View search terms used to find the site
Inputs: password (required), siteId (required), siteUrl (required), username (required), +2 more.
get-site-statsC
Get comprehensive stats for a WordPress site
Inputs: password (required), siteId (required), siteUrl (required), username (required), +1 more.
get-stats-highlightsC
Get highlight metrics for a WordPress site from the last seven days
Inputs: password (required), siteId (required), siteUrl (required), username (required).
get-stats-summaryC
View a site's summarized views, visitors, likes and comments
Inputs: password (required), siteId (required), siteUrl (required), username (required).
get-streak-statsC
Get stats for Calendar Heatmap showing publishing activity
Inputs: password (required), siteId (required), siteUrl (required), username (required).
get-top-postsC
View a site's top posts and pages by views
Inputs: password (required), siteId (required), siteUrl (required), username (required), +2 more.
get-userC
Get a specific user by ID
Inputs: password (required), siteUrl (required), userId (required), username (required), +1 more.
get-usersC
Get a list of users from a WordPress site with advanced filtering options
Inputs: password (required), siteUrl (required), username (required), capabilities, +13 more.
list-categoriesC
Get a list of categories with filtering options
Inputs: password (required), siteUrl (required), username (required), context, +11 more.
list-postsC
Get a list of posts with comprehensive filtering options
Inputs: password (required), siteUrl (required), username (required), after, +23 more.
remove-referrer-spamC
Unreport a referrer as spam
Inputs: domain (required), password (required), siteId (required), siteUrl (required), +1 more.
report-referrer-spamC
Report a referrer as spam
Inputs: domain (required), password (required), siteId (required), siteUrl (required), +1 more.
update-categoryC
Update an existing WordPress category
Inputs: categoryId (required), password (required), siteUrl (required), username (required), +5 more.
update-postC
Update an existing WordPress post
Inputs: password (required), postId (required), siteUrl (required), username (required), +18 more.
update-userC
Update an existing WordPress user
Inputs: password (required), siteUrl (required), userId (required), username (required), +12 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 29 tools
Each tool has a clearly distinct purpose targeting specific resources and actions. For example, create/delete/get/update operations are separated by resource type (category, post, user), and analytics tools (get-clicks, get-country-views, etc.) each focus on different metrics without overlap.
All tools follow a consistent verb_noun pattern with hyphens (e.g., create-post, get-category, update-user). The naming is uniform across all 29 tools, making them predictable and easy to understand.
With 29 tools, the count feels heavy for a WordPress server, as it combines content management (posts, categories, users) with extensive analytics. While each tool is useful, the set might be overwhelming for agents, suggesting it could be split into separate servers for content vs. stats.
The tool surface provides complete CRUD/lifecycle coverage for core resources (posts, categories, users) and includes comprehensive analytics for site stats, referrers, and spam management. There are no obvious gaps for the WordPress domain.
Maintenance
Related MCP Connectors
Manage your WordPress site from your AI assistant: posts, pages, media, comments and WooCommerce.
Manage WordPress blogs and WooCommerce shops from Claude, ChatGPT, Cursor and other MCP apps.
Manage your WordPress site from ChatGPT or Claude: posts, WooCommerce, SEO, images and upkeep.
Manage a WordPress site from your AI assistant: read, search, propose edits, Search Console data.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with WordPress sites through the WordPress REST API. Supports multiple WordPress sites with secure authentication, enabling content management, post operations, and site configuration through natural language.34 npm118MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with WordPress sites through the REST API. Supports multiple WordPress sites with secure authentication, enabling content management, post operations, and site configuration through natural language.34 npmMIT
- AlicenseAqualityDmaintenanceEnables AI assistants to manage WordPress sites through natural conversation, supporting post creation, content updates, site queries, and draft-to-publish workflows via the WordPress REST API.9MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with WordPress blog systems for automated content management and publishing via the WordPress REST API.18 npm1MIT