- Explore MCP Servers
- github
GitHub MCP Server
What is GitHub MCP Server
The GitHub MCP Server is a middleware component that facilitates interactions with the GitHub API, enabling users to perform various file operations, manage repositories, and execute advanced search functionalities seamlessly. It is designed to enhance productivity by automating common tasks associated with GitHub repositories.
Use cases
This server can be used for a variety of tasks including creating or updating files in repositories, managing branches, searching for repositories, issues, and users, as well as creating and managing pull requests and issues. It is particularly useful for developers and teams looking to integrate GitHub functionalities into their workflows or applications.
How to use
To use the GitHub MCP Server, users must create a GitHub Personal Access Token with appropriate permissions. This token is then configured within the server setup, either using Docker or NPX commands. After installation, users can invoke various API functionalities through defined commands, allowing for streamlined interactions with GitHub repositories.
Key features
Key features of the GitHub MCP Server include automatic branch creation for file operations, comprehensive error handling, preservation of Git history, support for batch operations, and advanced search capabilities across repositories, code, issues, pull requests, and users.
Where to use
The GitHub MCP Server is ideal for use in development environments, CI/CD pipelines, or any application where GitHub integration is required. It is particularly beneficial for teams working on collaborative projects, enabling them to manage their codebase and issues more efficiently.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is GitHub MCP Server
The GitHub MCP Server is a middleware component that facilitates interactions with the GitHub API, enabling users to perform various file operations, manage repositories, and execute advanced search functionalities seamlessly. It is designed to enhance productivity by automating common tasks associated with GitHub repositories.
Use cases
This server can be used for a variety of tasks including creating or updating files in repositories, managing branches, searching for repositories, issues, and users, as well as creating and managing pull requests and issues. It is particularly useful for developers and teams looking to integrate GitHub functionalities into their workflows or applications.
How to use
To use the GitHub MCP Server, users must create a GitHub Personal Access Token with appropriate permissions. This token is then configured within the server setup, either using Docker or NPX commands. After installation, users can invoke various API functionalities through defined commands, allowing for streamlined interactions with GitHub repositories.
Key features
Key features of the GitHub MCP Server include automatic branch creation for file operations, comprehensive error handling, preservation of Git history, support for batch operations, and advanced search capabilities across repositories, code, issues, pull requests, and users.
Where to use
The GitHub MCP Server is ideal for use in development environments, CI/CD pipelines, or any application where GitHub integration is required. It is particularly beneficial for teams working on collaborative projects, enabling them to manage their codebase and issues more efficiently.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
GitHub MCP Server
MCP Server for the GitHub API, enabling file operations, repository management, search functionality, and more.
Features
- Automatic Branch Creation: When creating/updating files or pushing changes, branches are automatically created if they don't exist
- Comprehensive Error Handling: Clear error messages for common issues
- Git History Preservation: Operations maintain proper Git history without force pushing
- Batch Operations: Support for both single-file and multi-file operations
- Advanced Search: Support for searching code, issues/PRs, and users
Search Query Syntax
Code Search
language:javascript
: Search by programming languagerepo:owner/name
: Search in specific repositorypath:app/src
: Search in specific pathextension:js
: Search by file extension- Example:
q: "import express" language:typescript path:src/
Issues Search
is:issue
oris:pr
: Filter by typeis:open
oris:closed
: Filter by statelabel:bug
: Search by labelauthor:username
: Search by author- Example:
q: "memory leak" is:issue is:open label:bug
Users Search
type:user
ortype:org
: Filter by account typefollowers:>1000
: Filter by followerslocation:London
: Search by location- Example:
q: "fullstack developer" location:London followers:>100
For detailed search syntax, see GitHub's searching documentation.
Setup
Personal Access Token
Create a GitHub Personal Access Token with appropriate permissions:
- Go to Personal access tokens (in GitHub Settings > Developer settings)
- Select which repositories you'd like this token to have access to (Public, All, or Select)
- Create a token with the
repo
scope (“Full control of private repositories”)- Alternatively, if working only with public repositories, select only the
public_repo
scope
- Alternatively, if working only with public repositories, select only the
- Copy the generated token
Installation
Local
{
"mcpServers": {
"github": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-github"
],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "YOUR_ACCESS_TOKEN"
}
}
}
}
Remote
{
"mcpServers": {
"github": {
"type": "streamable-http",
"url": "https://router.mcpso.cc/mcp/github"
}
}
}
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.
Tools
MCP Server Configuration
This MCP server is hosted, and you can test tools online for free after connecting.
Required Environment Variables
Personal Access Token for GitHub to authenticate API requests
To execute tools on this server, you must first configure environment variables and connect to the server.