GitHub

v0.1.0Version Controlstable

Local MCP server for safe GitHub developer workflows. Enables pulling main, creating feature branches, pushing them, and opening ready-for-review pull requests via tools like github_create_feature_branch and github_create_pull_request.

aeoapiclaudegeomcp
Share:
74
Stars
0
Downloads
0
Weekly
0/5

What is GitHub?

GitHub is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to local mcp server for safe github developer workflows. enables pulling main, creating feature branches, pushing them, and opening ready-for-review pull requests via tools like github_create_feature_bra...

Local MCP server for safe GitHub developer workflows. Enables pulling main, creating feature branches, pushing them, and opening ready-for-review pull requests via tools like github_create_feature_branch and github_create_pull_request.

This server falls under the Version Control category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • create_or_update_file
  • search_repositories
  • create_repository
  • get_file_contents
  • push_files

Use Cases

Safe GitHub workflows with branch and PR management
Automated code review and pull request operations
adelaidasofia

Maintainer

LicenseMIT License
Languagetypescript
Versionv0.1.0
UpdatedMay 4, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

NPM

npx -y @modelcontextprotocol/server-github

Manual Installation

npx -y @modelcontextprotocol/server-github

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use GitHub

This GitHub MCP server provides a focused set of safe GitHub developer workflow tools for AI assistants, covering file operations, pull request lifecycle management, Dependabot alert monitoring, and repository health checks. Unlike broader GitHub integrations, it emphasizes safe branch-based workflows: reading files via the Contents API, creating or updating files idempotently, listing and merging pull requests, and surfacing security alerts by severity. Developers use it to automate PR reviews, manage Dependabot alerts, and perform file-level operations on GitHub repositories entirely through natural language.

Prerequisites

  • A GitHub Personal Access Token (PAT) with scopes: Contents (read/write), Pull requests (read/write), Dependabot alerts (read)
  • Node.js 18 or later and npx available (for the @modelcontextprotocol/server-github package)
  • An MCP-compatible client such as Claude Desktop
  • Optional: GITHUB_API_BASE set to your GitHub Enterprise Server URL if not using github.com
1

Create a GitHub Personal Access Token

Go to GitHub Settings > Developer Settings > Personal access tokens > Fine-grained tokens. Create a token with Contents (R/W), Pull requests (R/W), and Dependabot alerts (R) permissions for the repositories you want to access.

2

Store the token securely

On macOS, store the PAT in the Keychain rather than in plain text in your config file. Alternatively, set it as GITHUB_TOKEN in your environment.

# macOS Keychain (recommended)
security add-generic-password -s github-mcp -a "$USER" -w "<your-PAT>"

# Or export as environment variable
export GITHUB_TOKEN=ghp_your_token_here
3

Configure Claude Desktop

Open claude_desktop_config.json and add the GitHub MCP server block. The server reads GITHUB_TOKEN or GH_TOKEN from the environment (GITHUB_TOKEN takes precedence).

{
  "mcpServers": {
    "github": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-github"],
      "env": {
        "GITHUB_TOKEN": "ghp_your_token_here"
      }
    }
  }
}
4

Restart Claude Desktop

Fully quit and relaunch Claude Desktop. The GitHub tools (health_check, list_prs, get_pr, merge_pr, list_dependabot_alerts, get_file, put_file) will be available.

5

Verify with a health check

Ask your AI assistant to run a health check to confirm your PAT is valid and see your current rate-limit availability.

GitHub Examples

Client configuration

Complete claude_desktop_config.json entry for the GitHub MCP server using the official @modelcontextprotocol/server-github package.

{
  "mcpServers": {
    "github": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-github"],
      "env": {
        "GITHUB_TOKEN": "ghp_your_personal_access_token"
      }
    }
  }
}

Prompts to try

Use these prompts to manage GitHub repositories, pull requests, and security alerts through your AI assistant.

- "List all open pull requests in my-org/my-repo"
- "Get the details and check run status for PR #42 in my-org/my-repo"
- "Merge PR #42 in my-org/my-repo using squash merge and delete the branch"
- "Show me all critical Dependabot alerts in my-org/my-repo"
- "Read the contents of src/index.ts in my-org/my-repo"

Troubleshooting GitHub

401 Unauthorized when calling GitHub tools

Verify GITHUB_TOKEN is set correctly in your config env block. Ensure the token has not expired and has the required scopes: Contents, Pull requests, and Dependabot alerts. Generate a new fine-grained PAT if needed.

Dependabot alerts tool returns permission denied

Dependabot alert access requires the token to have 'Dependabot alerts' read permission AND the repository must have Dependabot alerts enabled (Settings > Security > Dependabot alerts).

Rate limit errors after many tool calls

GitHub's REST API has rate limits (5000 requests/hour for authenticated users). Use the health_check tool to see remaining rate-limit quota. Consider using a fine-grained token with repo-specific scope to avoid sharing limits with other integrations.

Frequently Asked Questions about GitHub

What is GitHub?

GitHub is a Model Context Protocol (MCP) server that local mcp server for safe github developer workflows. enables pulling main, creating feature branches, pushing them, and opening ready-for-review pull requests via tools like github_create_feature_branch and github_create_pull_request. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install GitHub?

Install via npm with the command: npx -y @modelcontextprotocol/server-github. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).

Which AI clients work with GitHub?

GitHub works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is GitHub free to use?

Yes, GitHub is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Version Control MCP Servers

Explore all version control servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "github": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-github"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use GitHub?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides