Skip to content
MCP server

MainWP

Manage a MainWP WordPress network from an AI assistant, with approval gates

Runs locallyStatus and history
Install
Pricing
Open source
Platforms
CLI, self-hosted
Runs
Locally
Version
1.5.1
Listing updated
2 days ago

About MainWP

MainWP is an open-source MCP server for developer tools. It runs locally on your machine and is started by your AI client.

This official server sits between your AI client and a self-hosted MainWP Dashboard. The model turns a request into tool calls, the server decides which tools are visible and enforces that on every call, and the Dashboard remains the authority that holds the sites and does the WordPress work. It runs on your own computer, and nothing new is installed on the Dashboard or child sites.

Deleting a site, plugin or theme shows a preview and runs only after you approve; on Dashboard 6.3 and later, updates work the same way. Safe mode blocks destructive operations outright, and allow and block lists limit which tools the model sees. It signs in with a WordPress Application Password that you can revoke.

The README counts around 70 tools, depending on Dashboard version, covering sites, updates, plugins and themes, clients and tags, notes and memories for the AI to read, and guided workflows such as security audits and update plans. It needs Node.js 20.19 or later and MainWP Dashboard 6.0 or later over HTTPS. A Claude Code plugin adds ten /mainwp commands.

Install

Run in a terminal

claude mcp add mainwp-mcp --env MAINWP_URL='<MAINWP_URL>' --env MAINWP_USER='<MAINWP_USER>' --env MAINWP_APP_PASSWORD='<MAINWP_APP_PASSWORD>' -- npx -y @mainwp/mcp

Add to claude_desktop_config.json

{
  "mcpServers": {
    "mainwp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@mainwp/mcp"
      ],
      "env": {
        "MAINWP_URL": "<MAINWP_URL>",
        "MAINWP_USER": "<MAINWP_USER>",
        "MAINWP_APP_PASSWORD": "<MAINWP_APP_PASSWORD>"
      }
    }
  }
}

Add to ~/.cursor/mcp.json

{
  "mcpServers": {
    "mainwp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@mainwp/mcp"
      ],
      "env": {
        "MAINWP_URL": "<MAINWP_URL>",
        "MAINWP_USER": "<MAINWP_USER>",
        "MAINWP_APP_PASSWORD": "<MAINWP_APP_PASSWORD>"
      }
    }
  }
}

Add to .vscode/mcp.json

{
  "servers": {
    "mainwp-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@mainwp/mcp"
      ],
      "env": {
        "MAINWP_URL": "<MAINWP_URL>",
        "MAINWP_USER": "<MAINWP_USER>",
        "MAINWP_APP_PASSWORD": "<MAINWP_APP_PASSWORD>"
      }
    }
  }
}

Add to ~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "mainwp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@mainwp/mcp"
      ],
      "env": {
        "MAINWP_URL": "<MAINWP_URL>",
        "MAINWP_USER": "<MAINWP_USER>",
        "MAINWP_APP_PASSWORD": "<MAINWP_APP_PASSWORD>"
      }
    }
  }
}

Add to your client's MCP settings (most use this shape)

{
  "mcpServers": {
    "mainwp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@mainwp/mcp"
      ],
      "env": {
        "MAINWP_URL": "<MAINWP_URL>",
        "MAINWP_USER": "<MAINWP_USER>",
        "MAINWP_APP_PASSWORD": "<MAINWP_APP_PASSWORD>"
      }
    }
  }
}

Configuration

  • MAINWP_URLAddress of your MainWP Dashboard, such as https://dashboard.example.comRequired
  • MAINWP_USERWordPress username of the Dashboard administrator (the login name, not the display name)Required
  • MAINWP_APP_PASSWORDWordPress Application Password for that user, not their login passwordRequired

What it does

Network-wide updates
See pending core, plugin, theme and translation updates and apply them.
Approval gate
Deletions, and updates on Dashboard 6.3 and later, wait for your confirmation.
Safe mode
Blocks destructive operations entirely.
Tool allow and block lists
Choose which tools the AI can see.
Client and tag management
Manage client records, assign sites and track costs.
Guided workflows
Network summaries, site reports, security audits and update plans.
Claude Code plugin
Installs the server, a skill and ten workflow commands.

Good for

  • Find which sites have pending plugin updates
  • Update one plugin only on sites with a given tag
  • List sites that have not synced in 24 hours
  • Audit security across client sites
  • Check a client's notes before updating

Pricing

Open source

Prices change. Check docs.mainwp.com before you buy.

MainWP FAQ

What credentials does it use?

A WordPress Application Password for a Dashboard administrator, set through MAINWP_URL, MAINWP_USER and MAINWP_APP_PASSWORD.

Will it delete things without asking?

By default deletions show a preview and run only after approval; safe mode blocks them.

What do I need installed?

Node.js 20.19 or later and MainWP Dashboard 6.0 or later reachable over HTTPS.

Does it install anything on my sites?

No. Nothing new is installed on the Dashboard or child sites.

Is MainWP free?

Yes. MainWP is open source, so you can use and self-host it for free.

How do I add MainWP to Claude Code?

Run this command in your terminal: claude mcp add mainwp-mcp --env MAINWP_URL='<MAINWP_URL>' --env MAINWP_USER='<MAINWP_USER>' --env MAINWP_APP_PASSWORD='<MAINWP_APP_PASSWORD>' -- npx -y @mainwp/mcp

What are the best alternatives to MainWP?

The closest alternatives to MainWP are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

Alternatives to MainWP

  1. REA

    MCP server

    CLI and MCP server that lets coding agents reverse engineer apps and binaries

    Runs locally
    • Open source
    • 464K GitHub stars
    • Developer tools
  2. Codebase Memory

    MCP server

    Local MCP server that builds a code knowledge graph for AI coding agents

    Runs locally
    • Open source
    • 48.7K GitHub stars
    • Knowledge and memory
  3. GitHub

    MCP server

    Official MCP server connecting AI assistants to GitHub repos, issues and workflows

    Not checked yet
    • Remote
    • Open source
    • 34.5K GitHub stars
    • Developer tools
  4. MCP toolkit giving coding agents symbol-level code retrieval and editing

    Runs locally
    • Open source
    • 31.5K GitHub stars
    • Developer tools
  5. XERJ

    MCP server

    Local search engine for AI agents with cited answers over your code and docs

    Runs locally
    • Open source
    • 19.2K GitHub stars
    • Knowledge and memory
  6. Ouroboros

    MCP server

    Spec-first layer that pins requirements and verifies results of AI coding agent work

    Runs locally
    • Open source
    • 6.4K GitHub stars
    • Developer tools