PTS security notes / MCP servers / GitHub MCP server

Is GitHub MCP server safe to install?

By PTS · Based on public source as of December 5, 2026

Short answer

It can do almost anything your GitHub token can, including merging pull requests, pushing files, running workflows and deleting repositories. That is up to your token scope and the toolsets you enable. Use a fine-grained token limited to the repos you need, turn on --read-only when you only need reading, and enable only the toolsets you use.

What it is

GitHub's own MCP server exposes the GitHub API as tools, grouped into toolsets such as repos, issues, pull requests, Actions and code security. It runs locally in Docker or as a hosted endpoint, with an OAuth or token login.

Maintainer
Official (vendor)github on GitHub (organisation account, project of the same name)
Source
github/github-mcp-server35,003 GitHub stars · MIT licence
Transport
stdio (Docker or binary), Streamable HTTP (hosted endpoint)Hosted endpoint: https://api.githubcopilot.com/mcp/
Packages
github.com/github/github-mcp-server go
Latest release
GitHub MCP Server 2.3.0 2026-11-24
Public advisories
2GitHub and OSV, as of December 5, 2026

What it can do

Read from the public tool definitions in the source, not from a live run. A capability marked "yes" means at least one tool can do it.

The write tools act under your identity. Comments, reviews and pushed files appear as you, and an issue or PR body that your agent reads can try to steer it.

ToolWhat it can doNotes
delete_repositoryDeletesDeletes a repository. Not annotated read-only.
merge_pull_requestWritesMerges a pull request.
push_filesWritesPushes multiple files in one commit.
create_or_update_fileWrites
delete_fileDeletes
create_repositoryWrites
create_pull_requestWrites
create_issueWrites
add_issue_commentWrites, SendsPosts a public comment.
actions_run_triggerRuns code, WritesTriggers a workflow run.
create_gistWritesCan publish content publicly.
run_automationRuns code
update_pull_request_branchWrites
Read-annotated tools
71 tools
ReadsAnnotated read-only in the repo's tool snapshots. get_file_contents, list_issues, get_pull_request, search_code
Other write and update tools
88 tools
WritesIssues, PRs, reviews, notifications, security alerts, projects. Some list-style tools here lack a read-only hint in their snapshot. update_issue_*, update_pull_request_*, pull_request_review_write, label_write

Counted from the 159 tool snapshots in pkg/github/__toolsnaps__ in the repo. Which tools load depends on your toolsets, read-only flag and lockdown mode.

Credentials and least privilege

The token decides what the server can do, so it is the control that matters most.

CredentialWhat it is forLeast privilege
GITHUB_PERSONAL_ACCESS_TOKENAuthenticates API calls as you. OAuth is also supported on the hosted server.Use a fine-grained token on only the repositories you need, with the smallest permissions. The README lists repo, read:packages and read:org as the minimum classic scopes to consider, and says to use separate tokens per project and rotate them.

Public security advisories

Advisories published on GitHub or OSV for this project, as of December 5, 2026. Fixed issues are a normal part of a maintained project. What matters is that the version you run is not in an affected range.

AdvisorySeveritySummaryAffectedFixed in
GHSA-w4q6-qw23-4rg7 · CVE-2026-47427HighNil Pointer Dereference DoS in completion/complete Handler<= 0.33.0 (also affects latest main)n/a
GHSA-pjp5-fpmr-3349 · CVE-2026-48529ModerateLockdown mode singleton in HTTP server causes cross-user GraphQL client confusion>= 0.22.0, < 1.1.21.1.2

What stands out

Safe-install checklist

Install command from the project's docs: docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server.

  1. Pin the version. Use an exact version, not latest: docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server:v2.3.0. Pin the image tag, or a digest, and add --read-only to args when you do not need writes.
  2. Scope the credential. Use a fine-grained token on only the repositories you need, with the smallest permissions. The README lists repo, read:packages and read:org as the minimum classic scopes to consider, and says to use separate tokens per project and rotate them.
  3. Create a fine-grained token with access to selected repositories only, and give it read permissions unless you need writes.
  4. Start with --read-only and --toolsets for just what you use (for example repos and issues).
  5. Do not mix a token that can read private repos with tools that can post to public ones, without approving each post.
  6. Deny the tools you do not need. In Claude Code, deny rules in .claude/settings.json use the form mcp__<server name>__<tool>, where the server name is whatever you called it in your config. Example, if you named it github-mcp-server:
    {
      "permissions": {
        "deny": [
          "mcp__github-mcp-server__delete_repository",
          "mcp__github-mcp-server__merge_pull_request",
          "mcp__github-mcp-server__push_files",
          "mcp__github-mcp-server__create_or_update_file",
          "mcp__github-mcp-server__delete_file",
          "mcp__github-mcp-server__create_repository",
          "mcp__github-mcp-server__create_pull_request",
          "mcp__github-mcp-server__create_issue"
        ]
      }
    }
  7. Snapshot the tool list. Save the tools/list output right after you install, then compare it before every upgrade with the free PTS MCP tool diff checker. It runs in your browser and flags new tools and changed descriptions or schemas.
  8. Watch for fixes. Watch the project's security advisories and upgrade on purpose, after the diff.

For the general version of this list, see the MCP server security checklist. Not sure about a server that is not listed here? Read Is an MCP server safe to install?

Quick follow-ups

What can GitHub MCP server do on my machine or accounts?

Based on its public tool definitions, it can: reads local files or data; creates or changes files, records or settings; deletes or destroys data; runs commands, scripts or code; sends messages, posts or publishes for you. The write tools act under your identity. Comments, reviews and pushed files appear as you, and an issue or PR body that your agent reads can try to steer it.

Does GitHub MCP server need a token or API key?

Yes, depending on setup: GITHUB_PERSONAL_ACCESS_TOKEN. The token decides what the server can do, so it is the control that matters most.

Has GitHub MCP server had public security advisories?

Yes. 2 public advisories (GitHub or OSV) listed for it as of December 5, 2026. Each one is linked on this page with its affected and fixed versions, so you can check the version you run. Fixed issues are normal for active projects. Running a current, pinned version is what matters.

How do I keep GitHub MCP server from changing under me?

Pin the version, for example docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server:v2.3.0. Then save its tool list (name, description, input schema) with the free PTS MCP tool diff checker and compare it before each upgrade.

Sources

This page is a factual summary of public information about the software. It is not a verdict on the maintainers and not an audit. Check the project's own docs for your version before you rely on it. Educational, not legal or security advice.

Get the free checklist

A 9-page worksheet plus starter files for Claude Code and Codex. It maps what your agent can reach and shrinks it. Download it on Gumroad. This site does not collect email.

Get the free checklist

Before you install anything, try the MCP tool diff checker. See all 54 servers.

More server pages