AgentToolHub
MCP ServerClaude CodeCursorClineWindsurfVS Code

GitHub MCP Server

GitHub's official MCP Server

Features

  • ✓Repository management
  • ✓Issue and PR operations
  • ✓Code search
  • ✓GitHub Actions integration
  • ✓Gist management

Installation Guide

Install in GitHub Copilot on VS Code

For quick installation, use one of the one-click install buttons above. Once you complete that flow, toggle Agent mode (located by the Copilot Chat text input) and the server will start.

More about using MCP server tools in VS Code's agent mode documentation.

Install in GitHub Copilot on other IDEs (JetBrains, Visual Studio, Eclipse, etc.)

Add the following JSON block to your IDE's MCP settings.

json
{
  "mcp": {
    "inputs": [
      {
        "type": "promptString",
        "id": "github_token",
        "description": "GitHub Personal Access Token",
        "password": true
      }
    ],
    "servers": {
      "github": {
        "command": "docker",
        "args": [
          "run",
          "-i",
          "--rm",
          "-e",
          "GITHUB_PERSONAL_ACCESS_TOKEN",
          "ghcr.io/github/github-mcp-server"
        ],
        "env": {
          "GITHUB_PERSONAL_ACCESS_TOKEN": "${input:github_token}"
        }
      }
    }
  }
}

Optionally, you can add a similar example (i.e. without the mcp key) to a file called .vscode/mcp.json in your workspace. This will allow you to share the configuration with other host applications that accept the same format.

<details>
<summary><b>Example JSON block without the MCP key included</b></summary>
<br>

json
{
  "inputs": [
    {
      "type": "promptString",
      "id": "github_token",
      "description": "GitHub Personal Access Token",
      "password": true
    }
  ],
  "servers": {
    "github": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "${input:github_token}"
      }
    }
  }
}

</details>

Install in Other MCP Hosts

For other MCP host applications, please refer to our installation guides:

  • [Copilot CLI](docs/installation-guides/install-copilot-cli.md) - Installation guide for GitHub Copilot CLI

  • [GitHub Copilot in other IDEs](/docs/installation-guides/install-other-copilot-ides.md) - Installation for JetBrains, Visual Studio, Eclipse, and Xcode with GitHub Copilot

  • [Claude Code & Claude Desktop](docs/installation-guides/install-claude.md) - Installation guide for Claude Code and Claude Desktop

  • [Cursor](docs/installation-guides/install-cursor.md) - Installation guide for Cursor IDE

  • [Google Gemini CLI](docs/installation-guides/install-gemini-cli.md) - Installation guide for Google Gemini CLI

  • [Windsurf](docs/installation-guides/install-windsurf.md) - Installation guide for Windsurf IDE
  • For a complete overview of all installation options, see our [Installation Guides Index](docs/installation-guides).

    Note: Any host application that supports local MCP servers should be able to access the local GitHub MCP server. However, the specific configuration process, syntax and stability of the integration will vary by host application. While many may follow a similar format to the examples above, this is not guaranteed. Please refer to your host application's documentation for the correct MCP configuration syntax and setup process.

    Build from source

    If you don't have Docker, you can use go build to build the binary in the
    cmd/github-mcp-server directory, and use the github-mcp-server stdio command with the GITHUB_PERSONAL_ACCESS_TOKEN environment variable set to your token. To specify the output location of the build, use the -o flag. You should configure your server to use the built executable as its command. For example:

    JSON
    {
      "mcp": {
        "servers": {
          "github": {
            "command": "/path/to/github-mcp-server",
            "args": ["stdio"],
            "env": {
              "GITHUB_PERSONAL_ACCESS_TOKEN": "<YOUR_TOKEN>"
            }
          }
        }
      }
    }

    CLI utilities

    The github-mcp-server binary includes a few CLI subcommands that are helpful for debugging and exploring the server.

  • github-mcp-server tool-search "<query>" searches tools by name, description, and input parameter names. Use --max-results to return more matches.

  • Example (color output requires a TTY; use docker run -t (or -it) when running in Docker):
    bash
    docker run -it --rm ghcr.io/github/github-mcp-server tool-search "issue" --max-results 5
    github-mcp-server tool-search "issue" --max-results 5

    Reviews

    4.7★★★★☆(189 reviews)
    5★
    0%(0)
    4★
    0%(0)
    3★
    0%(0)
    2★
    0%(0)
    1★
    0%(0)