GitHub MCP Server

GitHub's official MCP server enables AI assistants to manage repositories, issues, pull requests, Actions workflows, and code security directly through natural language.

May 4, 2025
GitHub stars

Overview

The GitHub MCP Server is GitHub's official Model Context Protocol server. It connects AI tools directly to GitHub's platform, enabling AI agents to read repositories, manage issues and PRs, analyze code, monitor CI/CD workflows, and automate team processes — all through natural language.

Official Server:

Developed and maintained by GitHub

Key Features

📁

Repository Management

Browse and query code, search files, analyze commits, and understand project structure

📝

Issue & PR Automation

Create, update, and manage issues and pull requests with AI-assisted triage and review

🔄

CI/CD Intelligence

Monitor Actions workflows, analyze build failures, manage releases

🛡️

Code Security

Examine security findings, review Dependabot alerts, and manage secret scanning

👥

Team Collaboration

Access discussions, manage notifications, analyze team activity and organizations

🔌

Remote & Local Modes

Use GitHub-hosted remote server or run locally via Docker for full control

Available Toolsets

The server organizes tools into configurable toolsets. Enable only what you need.

ToolsetDescription
reposBrowse repositories, read files, search code, analyze commits
issuesCreate, read, update, search, and assign issues
pull_requestsCreate, review, merge, and manage PRs
actionsMonitor workflows, trigger runs, view logs
code_securityView code scanning alerts and security findings
discussionsRead and list team discussions
gistsCreate, read, and manage gists
gitLow-level Git operations via GitHub API
orgsManage organization teams and members
projectsWork with GitHub Projects boards
dependabotReview and manage dependency alerts
notificationsAccess and manage GitHub notifications

Key Tool Examples

get_file_contents

Retrieve file contents from any repository you have access to.

{
  "owner": "vercel",
  "repo": "next.js",
  "path": "packages/next/README.md"
}
issue_write

Create or update issues with labels, assignees, and milestones.

{
  "method": "create",
  "owner": "my-org",
  "repo": "my-repo",
  "title": "Add dark mode support",
  "body": "Implement dark mode toggle in settings",
  "labels": ["enhancement", "frontend"]
}
search_code

Search code across repositories with query syntax and filtering.

{
  "query": "useEffect cleanup function",
  "owner": "facebook",
  "repo": "react",
  "language": "typescript"
}
actions_get

Get details of Actions workflows, runs, jobs, and artifacts.

{
  "method": "get_workflow_run",
  "owner": "my-org",
  "repo": "my-repo",
  "resource_id": "1234567890"
}

Installation

{
  "servers": {
    "github": {
      "type": "http",
      "url": "https://api.githubcopilot.com/mcp/"
    }
  }
}

Authentication:

Remote mode uses OAuth via your MCP host. Local Docker mode requires a GitHub Personal Access Token with appropriate scopes.

Toolset Configuration

Control which GitHub capabilities are available to your AI:

# Minimal setup — issues and PRs only
GITHUB_TOOLSETS="repos,issues,pull_requests"

# Read-only mode — no write operations
GITHUB_TOOLSETS="repos,issues,pull_requests,actions,code_security"
--read-only

# All tools
GITHUB_TOOLSETS="all"

Sources