# Wechat Devtools MCP

> Wechat Devtools MCP is an open-source MCP server for developer tools. Let an AI editor compile, preview, debug and test WeChat mini programs. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** Windows, macOS, CLI
- **Repository:** https://github.com/watertian/wechat-devtools-mcp
- **MCP Registry name:** io.github.WaterTian/wechat-devtools-mcp
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-23

## About

The server wraps the WeChat DevTools command line so an assistant can run the whole mini-program loop of building, previewing, debugging and automated testing. It exposes seven aggregated tools, each with several actions, and the README calls it a thin MCP paired with a fat skill: workflows and best practice live in a companion wechat-devtools skill that must be installed too.

The README is in Chinese. It positions the project beside the IDE's own built-in MCP in DevTools 2.x: use the official one for opening, compiling, uploading and cloud work, and this one for stitched long-page screenshots and structured CDP console logs. Install with uv, enable the DevTools service port, and set two environment variables, the CLI path and the project path, on Windows or macOS.

A status action checks that the CLI, project, Node.js 18+ and service port are in order. Port 9222 can be changed through WECHAT_CDP_PORT if Chrome holds it. Cloud functions and databases are left to a separate CloudBase MCP.

## Features

- **Seven aggregated tools:** IDE, build, automator, inspector, screenshot, navigate and file tools with multiple actions.
- **Long-page screenshots:** Stitches full-page captures and reports honestly when a page cannot be captured fully.
- **CDP log capture:** Collects structured console logs grouped by page and denoised.
- **Automated page testing:** Tap, input, read data, mock wx calls and evaluate code in a running mini program.
- **Environment self-check:** The status action reports CLI, project, port and version problems.
- **Companion skill:** A skill carries nine task procedures and troubleshooting guidance.

## Good for

- Compile and preview a mini program from an editor
- Collect console errors across several pages
- Capture a long-page screenshot for review
- Script tap and input tests on a running mini program

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add wechat-devtools-mcp --env WECHAT_DEVTOOLS_CLI='<WECHAT_DEVTOOLS_CLI>' --env WECHAT_PROJECT_PATH='<WECHAT_PROJECT_PATH>' -- uvx wechat-devtools-mcp
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add wechat-devtools-mcp --env WECHAT_DEVTOOLS_CLI='<WECHAT_DEVTOOLS_CLI>' --env WECHAT_PROJECT_PATH='<WECHAT_PROJECT_PATH>' -- uvx wechat-devtools-mcp
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.wechat-devtools-mcp]
command = "uvx"
args = ["wechat-devtools-mcp"]
env = { WECHAT_DEVTOOLS_CLI = "<WECHAT_DEVTOOLS_CLI>", WECHAT_PROJECT_PATH = "<WECHAT_PROJECT_PATH>" }
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Or run: gemini mcp add -s user -e WECHAT_DEVTOOLS_CLI='<WECHAT_DEVTOOLS_CLI>' -e WECHAT_PROJECT_PATH='<WECHAT_PROJECT_PATH>' wechat-devtools-mcp uvx -- wechat-devtools-mcp

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

The AI Assistant docs only show command and args. If the env block is ignored, use Junie for this server.

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "wechat-devtools-mcp": {
      "command": "uvx",
      "args": [
        "wechat-devtools-mcp"
      ],
      "env": {
        "WECHAT_DEVTOOLS_CLI": "<WECHAT_DEVTOOLS_CLI>",
        "WECHAT_PROJECT_PATH": "<WECHAT_PROJECT_PATH>"
      }
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 7 names don't say. From the server's own tool labels and tool names; not verified by us.

- `wechat_ide`: IDE lifecycle and environment diagnosis: open, login, close, quit, status.
- `wechat_build`: Compile, preview, upload, build npm and clean cache.
- `wechat_automator`: Automated interaction and runtime queries such as tap, input, set_data, evaluate and storage.
- `wechat_inspector`: Runtime log capture through console and CDP.
- `wechat_screenshot`: Stitched long-page screenshots.
- `wechat_navigate`: Jump to a page and collect CDP logs.
- `wechat_file`: Read project info, pages and files.

## FAQ

### What do I need installed?

Python 3.10 or newer, Node.js 18 or newer, and WeChat DevTools 2.x or 1.06.x.

### Which settings are required?

Two environment variables: WECHAT_DEVTOOLS_CLI and WECHAT_PROJECT_PATH, plus the DevTools service port enabled.

### Does Wechat Devtools MCP replace the official built-in MCP?

No. The README says they complement each other and suggests the official one for opening, compiling and cloud work.

### Which systems are supported?

Windows and macOS.

### Is Wechat Devtools MCP free?

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

### How do I add Wechat Devtools MCP to Claude Code?

Run this command in your terminal: claude mcp add wechat-devtools-mcp --env WECHAT_DEVTOOLS_CLI='<WECHAT_DEVTOOLS_CLI>' --env WECHAT_PROJECT_PATH='<WECHAT_PROJECT_PATH>' -- uvx wechat-devtools-mcp

### What are the best alternatives to Wechat Devtools MCP?

The closest alternatives to Wechat Devtools MCP are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/wechat-devtools-mcp
