Github MCP Server

Enables programmatic interaction with the GitHub API for file operations, repository management, search, and more.

Local serverstdioTypeScript 9

What is the Github MCP server?

Connect Github to Claude, Cursor or any other MCP client and it stops being a tab you switch to. Enables programmatic interaction with the GitHub API for file operations, repository management, search, and more. The github mcp server is what makes that connection.

What the server does

  • Automatic Branch Creation — When creating/updating files or pushing changes, branches are automatically created if they don't exist
  • Comprehensive Error Handling — Clear error messages for common issues
  • Git History Preservation — Operations maintain proper Git history without force pushing
  • Batch Operations — Support for both single-file and multi-file operations
  • Advanced Search — Support for searching code, issues/PRs, and users

Installation

Setup follows the usual MCP pattern — install or clone the server, register it in your client's configuration file, restart the client. The configuration blocks on this page cover the common clients.

Available tools

The toolset is worth reading before you wire it up, because it tells you what the integration is really for:

  • Inputs — - owner (string): Repository owner (username or organization)
  • Returns — File content and commit details
  • list_repository_webhooks — get_repository_webhook
  • create_repository_webhook — update_repository_webhook
  • delete_repository_webhook — get_repository_webhook_config
  • update_repository_webhook_config — ping_repository_webhook
  • list_repository_webhook_deliveries — get_repository_webhook_delivery
  • redeliver_repository_webhook_delivery — list_organization_webhooks
  • get_organization_webhook — create_organization_webhook
  • update_organization_webhook — delete_organization_webhook
  • get_organization_webhook_config — update_organization_webhook_config
  • ping_organization_webhook — list_organization_webhook_deliveries

Credentials and setup notes

Configuration is passed through the environment: GITHUB_PERSONAL_ACCESS_TOKEN, YOUR_TOKEN. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

Worth knowing first

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 14 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Github.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

Where it fits

Among the developer tooling options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Github's toolset — Inputs, Returns, list_repository_webhooks and 11 more — is a fair guide to whether it matches your workflow. It is maintained by MissionSquad; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Available tools

ToolWhat it does
Inputs- owner (string): Repository owner (username or organization)
ReturnsFile content and commit details
list_repository_webhooksget_repository_webhook
create_repository_webhookupdate_repository_webhook
delete_repository_webhookget_repository_webhook_config
update_repository_webhook_configping_repository_webhook
list_repository_webhook_deliveriesget_repository_webhook_delivery
redeliver_repository_webhook_deliverylist_organization_webhooks
get_organization_webhookcreate_organization_webhook
update_organization_webhookdelete_organization_webhook
get_organization_webhook_configupdate_organization_webhook_config
ping_organization_webhooklist_organization_webhook_deliveries
get_organization_webhook_deliveryredeliver_organization_webhook_delivery
insecure_ssl"1" disables certificate verification and is discouraged.

How to install the Github MCP server

{
  "mcpServers": {
    "github": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "mcp/github"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "<YOUR_TOKEN>"
      }
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
GITHUB_PERSONAL_ACCESS_TOKENCredential the server authenticates with.Yes
YOUR_TOKENCredential the server authenticates with.Yes

Example prompts to try

  • Use Github to Inputs.
  • Use Github to Returns.
  • Use Github to list repository webhooks.

Frequently asked questions

This tool allows you to programmatically interact with the GitHub API, enabling automated file operations, repository management, advanced search, issue/PR creation, and more. Streamline your development workflows and automate repetitive tasks.