Data as of

GitHub MCP Server for Cursor: Setup & Config

GitHub MCP Server connects Cursor to repository content, issues, pull requests, and platform workflows.

GitHub MCP Server Cursor configuration

  1. Choose Cursor configuration scope

    For GitHub MCP Server, open Project: .cursor/mcp.json User: ~/.cursor/mcp.json. Merge into mcpServers at project or user scope.

  2. Add GitHub MCP Server to Cursor

    Use the github-mcp-server entry below in mcpServers. Keep GitHub MCP Server's documented stdio connection fields and your other Cursor entries.

  3. Check GitHub MCP Server in Cursor

    GitHub MCP Server: Enable in Cursor’s MCP settings; inspect tools.

Config file · Project: .cursor/mcp.json

User: ~/.cursor/mcp.json

JSON
{
  "mcpServers": {
    "github-mcp-server": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "<your GitHub personal access token with appropriate permissions>"
      }
    }
  }
}

GitHub in Cursor: stdio checks

  • Cursor must find docker and a running Docker engine for GitHub MCP Server. Enable the project/user entry in MCP settings and inspect its tools.
  • Review GITHUB_PERSONAL_ACCESS_TOKEN for GitHub MCP Server before sharing project .cursor/mcp.json; project scope travels with the repository.
  • GitHub MCP Server uses stdio here: Cursor must keep the configured process running; protocol output belongs on stdout and diagnostics on stderr.

GitHub MCP Server — details. Cursor guide

Frequently asked questions

Cursor's GitHub MCP Server entry belongs under mcpServers in .cursor/mcp.json (project) or ~/.cursor/mcp.json (user). Confirm the active scope in MCP settings.

Cursor's github-mcp-server example uses stdio.

GitHub MCP Server's Cursor configuration invokes docker and a running Docker engine.

Cursor's GitHub MCP Server example references GITHUB_PERSONAL_ACCESS_TOKEN. Check these names if startup or authentication fails; the example alone does not distinguish required from optional values.