Payload MCP Server

MCP server for Payload CMS 3.0, designed to help developers validate code, generate templates, and scaffold projects following best practices.

Local serverstdioTypeScript

What is the Payload MCP Server?

MCP server for Payload CMS 3.0, designed to help developers validate code, generate templates, and scaffold projects following best practices.

The short version

A powerful Model Context Protocol (MCP) server for Payload CMS that enables AI assistants to help you develop, manage, and extend your Payload CMS projects.

Payload MCP (Model Context Protocol) is a specialized server that connects AI assistants to your Payload CMS development workflow. It provides a set of tools for generating code, validating components, scaffolding projects, and performing specialized queries - all accessible to AI agents through the standardized Model Context Protocol.

  • Code Generation — Create collections, fields, config files, access control rules, hooks, endpoints, plugins, blocks, migrations, and components with the right structure and best practices
  • Validation — Validate your Payload CMS components to ensure they follow best practices and will work correctly
  • Scaffolding — Set up new Payload CMS projects with the right file structure and dependencies
  • Specialized Queries — Get recommendations and insights for your Payload CMS codebase
  • MCP Compliant — Works with any AI assistant that supports the Model Context Protocol
  • Local-first — Run entirely on your local machine for privacy and security

What it needs from you

  • Node.js (v16 or higher) - npm or Bun (recommended)

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

Maintainer setup documentation.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
collectionGenerate a Payload collection with fields, hooks, and access control
fieldGenerate a field configuration for collections
configGenerate a Payload configuration file
access-controlGenerate access control functions
hookGenerate before/after hooks for collections
pluginGenerate a Payload plugin
blockGenerate a block for the Payload block field type
migrationGenerate a database migration
componentGenerate a React component for the admin panel
validate_queryValidate and format Payload queries
get_query_suggestionsGet suggestions for Payload queries based on your collections
format_responseFormat the response from a Payload query
create_projectCreate a new Payload CMS project with recommended structure

How to install the Payload MCP Server

{
  "mcpServers": {
    "payload": {
      "command": "npx",
      "args": ["-y", "@ngyngcphu/payload-mcp"]
    }
  }
}

Add to claude_desktop_config.json, then restart Claude Desktop.

Configuration

  • Node.js (v16 or higher) - npm or Bun (recommended)

Example prompts to try

  • “Use Payload MCP to collection.”
  • “Use Payload MCP to field.”
  • “Use Payload MCP to config.”

Frequently asked questions

Node.js v16 or higher and npm (Bun recommended). The server runs locally and communicates over HTTP.