GitHub MCP Server
$ github-mcp-server Official Med RiskThe official Go-based GitHub Model Context Protocol server exposes GitHub repositories, issues, pull requests, code security, and Actions over MCP (stdio or tool-search). It includes granular scoping flags (--toolsets, --tools, --features=<list>), --read-only / GITHUB_READ_ONLY=1 safety enforcement, --gh-host <url> for GitHub Enterprise, --insiders, and --export-translations.
brew install github-mcp-server Use github-mcp-server (with --read-only and tool-search or scoped --toolsets/--features) inside IDE/hosted MCP clients, while preferring gh CLI in local shell coding agents for lower token overhead.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Purpose-built JSON-RPC MCP bridge supporting stdio, tool-search dynamic discovery, --features=<list> / --toolsets scoping, --export-translations, --insiders, and --gh-host.
stdioandtool-searchsubcommands with--features,--toolsets, and--toolsscoping--export-translationsand--gh-host <url>support
Provides hard --read-only (GITHUB_READ_ONLY=1) enforcement, lockdown mode against untrusted public repo content, and scoped GITHUB_PERSONAL_ACCESS_TOKEN env auth.
--read-only/GITHUB_READ_ONLY=1strips mutating tools- Relies on user-scoped
GITHUB_PERSONAL_ACCESS_TOKEN
Single static Go binary installable via brew install github-mcp-server, GitHub Releases, or official Docker image across macOS, Linux, and Windows.
brew install github-mcp-serverand official Docker/binary builds
tool-search and --toolsets/--tools filtering mitigate the classic MCP schema-bloat problem, though gh --json --jq remains leaner in shell agents.
- On-demand
tool-searchand toolset filtering reduce context bloat
Official GitHub repository (github/github-mcp-server) actively maintained under MIT.
- Official
github/github-mcp-serverrepository
Thorough README and configuration docs detailing stdio, tool-search, --read-only, --export-translations, and Enterprise --gh-host.
- Official docs in
github/github-mcp-serverREADME
Security, Auth & Guardrails
Reads GITHUB_PERSONAL_ACCESS_TOKEN from environment or MCP client host configuration; supports --gh-host for Enterprise endpoints.
MIT open-source and free; subject to standard GitHub API rate limits.
# GitHub MCP Server Agent Rules - Prefer `--read-only` (or `GITHUB_READ_ONLY=1`) and narrow `--toolsets`/`--tools` unless GitHub write actions are explicitly requested. - Use `tool-search` or scoped `--features=<list>` to keep MCP context overhead small; never hardcode `GITHUB_PERSONAL_ACCESS_TOKEN` in committed config files.
Agent-Ready Command Recipes
Safe Read-Only Queries
github-mcp-server --export-translations
Prints the JSON translation/config map of tool descriptions to stdout and exits without connecting to GitHub.
GITHUB_PERSONAL_ACCESS_TOKEN="$GITHUB_TOKEN" github-mcp-server stdio --read-only --toolsets=repos,issues,pull_requests
Launches the stdio JSON-RPC MCP server with --read-only so mutating GitHub tools are excluded.
Controlled Writes & Previews
GITHUB_PERSONAL_ACCESS_TOKEN="$GITHUB_TOKEN" github-mcp-server stdio --toolsets=repos,pull_requests --features=issues
Exposes scoped read/write GitHub tools over stdio while avoiding unnecessary toolset schema bloat.
Strengths for Agents
- + Official Go MCP server with
--read-onlyenforcement and lockdown security mode. - +
tool-search,--toolsets,--tools, and--features=<list>curb context-window schema bloat. - + Supports GitHub Enterprise Server via
--gh-host <url>,--insiders, and--export-translations.
Caveats & Pitfalls
- !
stdiois a JSON-RPC server protocol intended for MCP hosts rather than ad-hoc human terminal commands. - ! Without
--toolsetsortool-search, loading all GitHub tools consumes significant LLM context compared toghCLI.