GitHub MCP Server
Interact with GitHub repositories, issues, pull requests, and the GitHub API.
claude_desktop_config.json
{
"mcpServers": {
"server-github": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-github"
],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "your-token-here"
}
}
}
} Environment Variables
| Variable | Required | Description |
|---|---|---|
GITHUB_PERSONAL_ACCESS_TOKEN | ✓ Required | GitHub personal access token with the required repo scopes. |
Setup Instructions
- Ensure Node.js 18+ is installed on your system.
-
Copy the config block above into your
claude_desktop_config.jsonfile (typically at~/.config/claude/claude_desktop_config.jsonon macOS/Linux or%APPDATA%\Claude\claude_desktop_config.jsonon Windows). - Set the
GITHUB_PERSONAL_ACCESS_TOKENenvironment variable: GitHub personal access token with the required repo scopes. - Restart your AI client to apply the config.