GitHub MCP Server
GitHub MCP Server enables AI agents to manage repos, read/update files, handle issues/PRs, branches, and automate GitHub workflows via the API.
GitHub MCP Server enables AI agents to manage repos, read/update files, handle issues/PRs, branches, and automate GitHub workflows via the API.
Real data. Real impact.
Growing
Developers
Per week
Open source
Skills give you superpowers. Install in 30 seconds.
Complete GitHub Integration for AI Agents
Connect AI agents to GitHub for repository management, code operations, issue tracking, pull requests, and the full GitHub API.
Enable agents to perform complex GitHub operations that previously required manual API integration:
OAuth-based authentication with fine-grained permissions. Agents access only what you authorize.
Pre-configured tools for the most common GitHub workflows. No manual API calls required.
# Community-maintained GitHub MCP server npm install -g @modelcontextprotocol/server-githubOr build from source
git clone https://github.com/modelcontextprotocol/servers-archived cd servers-archived/src/github npm install npm run build
Several community implementations available. Check the MCP Registry for current options.
Add to your MCP client config:
{ "mcpServers": { "github": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-github"], "env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_your_token_here" } } } }
repo - Full repository accessread:user - Read user profileread:org - Read organization data (if needed)Fine-Grained Token (recommended):
Agent: "Create a new repository called 'my-project'"
Agent: "Clone the OpenAI GPT-4 repository"
Agent: "What files are in the src/ directory?"
Agent: "Show me the README.md file" Agent: "Read the contents of src/index.ts"
Agent: "Create a new file docs/API.md with API documentation" Agent: "Update the version in package.json to 2.0.0"
Agent: "Search for files containing 'authentication logic'" Agent: "Find where the DatabaseConnection class is defined"
Agent: "Create an issue: 'Add dark mode support'"
Agent: "Show me all open bugs" Agent: "What issues are assigned to me?"
Agent: "Create a PR to merge feature/login into main"
Agent: "Review PR #42 and check for security issues"
Agent: "Create a new branch called 'feature/user-auth'"
Agent: "Show all branches in this repo"
Agent: "Merge 'develop' into 'main'"
Agent: "Create a release v2.0.0 with the latest changes"
Agent: "Find popular React component libraries"
Agent: "Fork the Vue.js repository to my account"
Human: "Review all PRs and flag security issues"Agent:
- list_pull_requests(state="open")
For each PR:- get_pull_request(pr_number)
- read_changed_files()
- analyze for security vulnerabilities
create_review_comment(security_findings)
Human: "Label all new issues with 'needs-triage'"Agent:
- list_issues(state="open", labels=null)
For each unlabeled issue:- read_issue(issue_number)
add_label("needs-triage")
Human: "Prepare v2.0.0 release"Agent:
- create_branch("release/v2.0.0")
- update_file("package.json", version="2.0.0")
- update_file("CHANGELOG.md", new_release_notes)
- create_pull_request("release/v2.0.0" -> "main")
create_release(tag="v2.0.0", notes=changelog)
Human: "Update documentation from code comments"Agent:
- search_code(query="* @description")
- extract_docstrings()
- generate_markdown_docs()
- update_file("docs/API.md", generated_docs)
create_pull_request("Update API documentation")
Agents that help developers with repetitive GitHub tasks: creating issues, managing labels, updating documentation, code review.
Build agents that trigger workflows, check build status, create releases, manage deployments.
Analyze code quality, track issue resolution time, monitor PR velocity, generate reports.
Find code patterns, identify dependencies, discover similar implementations, locate technical debt.
Sync code comments to docs, generate API references, update changelogs, maintain README files.
Prefer fine-grained tokens over classic PATs. Limit scope to specific repositories and permissions.
If the agent only needs to read code/issues, grant read-only access.
Never hard-code tokens. Always use environment variables.
Rotate tokens regularly. Set expiration dates.
Monitor what the agent does. GitHub activity log tracks all API operations.
Authenticated Requests:
Best Practices:
If-None-Match headers)| Task | Manual API | GitHub MCP |
|---|---|---|
| Setup Time | Hours (auth, SDK, error handling) | Minutes (config file) |
| Code Required | Yes (HTTP client, auth, parsing) | No (MCP tools auto-discovered) |
| Agent Integration | Manual tool definitions | Automatic via MCP |
| Auth Management | Custom implementation | Built-in OAuth flow |
| Error Handling | Custom retry logic | Handled by server |
repo, read:user)owner/repoX-RateLimit-Reset header){ "mcpServers": { "github": { "command": "node", "args": ["/path/to/github-mcp/build/index.js"], "env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_xxx", "GITHUB_API_URL": "https://api.github.com", "DEFAULT_BRANCH": "main", "AUTO_PAGINATION": "true" } } } }
The GitHub integration every coding agent needs: From code review to release automation, GitHub MCP brings the full power of GitHub to AI agents.
No automatic installation available. Please visit the source repository for installation instructions.
View Installation Instructions1,500+ AI skills, agents & workflows. Install in 30 seconds. Part of the Torly.ai family.
© 2026 Torly.ai. All rights reserved.