Craft MCP is an MCP (Model Context Protocol) server for Craft CMS. It gives AI assistants direct access to your installation's content, schema, and configuration: rather than describing your field layouts or Matrix setups by hand, the assistant queries them, writes reviewable draft content in a natural-key format, and inspects the system it is working in.
It ships more than 50 specialized tools, 10 analysis prompts, and 13 data resources, served over stdio for local development and over HTTP with scoped bearer tokens for remote users.
composer require stimmt/craft-mcp
php craft plugin/install mcpEnable the server in config/mcp.php (it is disabled in production by default):
<?php
return [
'enabled' => true,
];Then run the interactive wizard to configure your MCP clients:
php craft mcp/installThat is the whole happy path. For manual client configuration (Claude Code, Cursor, Claude Desktop, Codex, SSH), see the Client Setup guide; for all options including tool disabling, IP allowlists, and environment defaults, see the Configuration guide.
Content editors and office users can connect Claude (web, Desktop or mobile) straight to a remote install: add the site as a custom connector by its URL, log in to Craft, and choose what Claude may do. The plugin serves the MCP protocol from a Craft endpoint, with access scoped per user to readonly, content, or full; clients that send headers can use per-user bearer tokens instead. Off by default; enabling it, connecting Claude, minting tokens (php craft mcp/tokens/create), and troubleshooting are covered in the HTTP Transport guide.
Entry reads and writes share one payload format: relations as natural keys ({"section": "pages", "slug": "about"}), Matrix blocks by type handle, and per-field input shapes from describe_entry_schema that tell an agent exactly what every field accepts, third-party fields included. Writes land as reviewable drafts with a control panel deep link, and publish_entry makes them live. The full format, workflow, and schema discovery are covered in the Content Writing guide.
| Category | Highlights |
|---|---|
| Content | Entries (payload-format read/write, field/relation/date filters, count and group-by breakdowns, draft workflow with a pending-drafts review queue and revision history, publish/duplicate/copy to site), schema discovery via describe_entry_schema, assets, categories, users, globals |
| System | System info, config, logs, caches, routes, console commands |
| Database | Schema inspection, table counts, read-only queries |
| Debugging | Queue jobs, project config diff, deprecations, EXPLAIN, event handlers, and a Tinker tool for executing PHP in the Craft context |
| Multi-Site | Sites, site groups, per-site details |
| GraphQL | Schemas, SDL, read-only and mutating query execution, tokens |
| Backup | Create and list database backups |
| Self-Awareness | Plugin info, tool listing with risk annotations, hot reload |
| Commerce | Products, orders, and statuses (when Craft Commerce is installed) |
The eight tools that write entry content require the Pro edition; everything else is available on Lite. See Editions.
Tools that modify data or execute code are flagged dangerous: they sit behind the enableDangerousTools setting, carry a destructiveHint annotation in tools/list, and are excluded from readonly and (except entry workflow) content HTTP scopes. See the Tools Overview for the complete reference.
Other plugins and modules can register their own tools, prompts, resources, and field translators through events (EVENT_REGISTER_TOOLS, EVENT_REGISTER_FIELD_TRANSLATORS, and friends). See the Extending guide for implementation details and examples.
The documentation index links everything; the direct routes:
- Installation - Requirements, Composer setup, detailed installation steps
- Client Setup - Wizard and manual configs for Claude Code, Cursor, Claude Desktop, Codex
- Configuration - All configuration options and security settings
- Editions - What Lite and Pro each include, and how a Lite install behaves
- HTTP Transport - Remote access: connect the Claude apps by URL with a Craft login, or per-user scoped bearer tokens for other clients
- Using Claude with your Craft site - A short guide to send editors once the connector is on
- Content Writing - The payload format, draft workflow, and schema discovery for agents
- Tools Reference - Complete documentation for every tool
- Prompts - Pre-built analysis prompts
- Resources - Read-only URI-based access to schema, config, and content data
- Extending - Register custom tools, prompts, resources, and field translators
Thank you for considering contributing to Craft MCP! Please see GitHub Issues for bug reports, feature requests, and discussion.
- Created and maintained by Max van Essen
- Inspired by Laravel Boost
- Plugin icon from Lucide (MIT)
Craft MCP is open-sourced software licensed under the MIT license.