How to Configure Drupal MCP with Claude Desktop

The Drupal MCP module allows Claude Desktop to interact directly with your Drupal site. With MCP enabled, Claude Desktop can perform actions such as creating content, managing configuration, interacting with fields, using selected Drush commands, and running custom MCP plugins. This guide shows how to install MCP, enable plugins, set up a secure MCP user, and connect Claude Desktop through the STDIO transport.
Install and Enable the MCP Module
Run the following in your existing Drupal project:
composer require drupal/mcp
drush en mcp -yMCP uses plugins to define available features. The core module provides the protocol. Plugins expose actions and tools that Claude Desktop can use.
Optional submodules
- mcp_extra integrates with the Drupal AI module
- mcp_dev_tools exposes selected Drush commands
Enable as needed:
drush en mcp_extra -y
drush en mcp_dev_tools -yIf you enable mcp_extra, install and enable the Drupal AI module.
Configure the MCP Server
- Open the MCP settings page: /admin/config/mcp
You can enable authentication, select which plugins will be active, choose content types to expose, and configure permissions.
Create a dedicated MCP user
For security, create a new Drupal user for Claude Desktop. For example, mcp_admin.
Grant only:
- Use MCP server
Use this account for all MCP authentication.
Connecting Drupal MCP to Claude Desktop
Claude Desktop communicates with Drupal MCP using the STDIO transport. This requires running the official MCP companion server inside a Docker container.
You will need Docker Desktop, Colima, or any Docker-compatible runtime. Claude Desktop will launch the container each time it connects.
Below is the recommended configuration block for Claude Desktop. It goes into the file:
- macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
- Windows: %APPDATA%/Claude/claude_desktop_config.json
For this example, if the URL to your Drupal site http://drupal-mcp.ddev.site.
Claude Desktop MCP configuration:
{
"mcpServers": {
"mcp-server-drupal": {
"command": "docker",
"args": [
"run", "-i", "--rm",
"-e", "DRUPAL_AUTH_USER={{MCP_USER}}",
"-e", "DRUPAL_AUTH_PASSWORD={{PASSWORD}}",
"--network=host", "ghcr.io/omedia/mcp-server-drupal:latest",
"--drupal-url=http://drupal-mcp.ddev.site",
"--unsafe-net"
],
"env": {
"DRUPAL_AUTH_USER": "{{MCP_USER}}",
"DRUPAL_AUTH_PASSWORD": "{{PASSWORD}}"
}
}
}
}
Save the file, then quit and reopen Claude Desktop. Your Drupal MCP server will appear in the list of connected servers if the configuration is correct.
What You Can Do With Claude Desktop and Drupal MCP
After connecting, Claude Desktop can interact with your site in powerful ways, such as:
- Creating and updating content
- Managing fields and content types
- Configuring blocks and view displays
- Exporting and importing configuration
- Running controlled Drush commands when mcp_dev_tools is enabled
- Using your own MCP plugins for custom workflows
This provides a streamlined, AI-assisted workflow that can handle repeatable tasks and complex Drupal operations.
Related Content

Saplings AI MCP
A recipe to enable a fully compliant MCP server on your Drupal site for seamless AI-powered interactions.

Drupal + NextJS Starter
This project provides a starter kit for evaluating a headless Drupal setup with Next.js. It combines Drupal 11 as the content backend with a Next.js 15 frontend, including JSON:API, OAuth, TypeScript, and Tailwind. The environment is containerized using Docker/Docksal, and the repository can be cloned and initialized for testing. The kit is intended to help assess Drupal’s suitability as a backend for a modern Next.js application.

What is an MCP server and how does it work?
MCP servers and clients connect AI tools such as Claude, Cursor, and ChatGPT to thousands of external systems via a standard protocol.