GitHub (read-only) MCP server
io.github.AbdulMuhaiminKhan · Updated
Read-only GitHub repos, issues, PRs and commits, with tool descriptions tuned on a benchmark.
At a glance
GitHub (read-only) is an MCP server in the Dev Tools & Git category. It runs locally over stdio via `uvx github-mcp-readonly`, and needs GITHUB_TOKEN. It exposes 3 tools, including server.py, descriptions.py and github_client.py. It scores B (76/100) on the MCP Skills Hub health score as of Oct 28, 2026.
One-click install
Opens your editor and pre-fills the config. Your editor will ask before adding it.
How to install GitHub (read-only) in your AI client
Setup for Claude Code, Claude Desktop, Cursor, Codex, Windsurf, Cline and VS Code — copy-paste ready.
How to install GitHub (read-only) in Claude CodeAnthropic's agentic CLI
Add the server
bashclaude mcp add github-mcp -e 'GITHUB_TOKEN=<GITHUB_TOKEN>' -- uvx github-mcp-readonlyFill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Verify it's connected
bashclaude mcp listSharing it with your team?
Add `--scope project` to write it to .mcp.json in the repository root, which you can commit (with the secrets left as environment variables).
Use it in a session
Ask Claude to use the tools this server exposes (e.g. server.py, descriptions.py, github_client.py). It discovers them automatically.
How to install GitHub (read-only) in Claude DesktopDesktop app (MCP config)
Open your MCP config
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json · Windows: %APPDATA%\Claude\claude_desktop_config.json
Add this server
json{ "mcpServers": { "github-mcp": { "command": "uvx", "args": [ "github-mcp-readonly" ], "env": { "GITHUB_TOKEN": "<GITHUB_TOKEN>" } } } }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Restart Claude Desktop
The tools appear under the 🔌 menu once the app reloads.
How to install GitHub (read-only) in CursorAI-first code editor
Create / edit .cursor/mcp.json in your project
json{ "mcpServers": { "github-mcp": { "command": "uvx", "args": [ "github-mcp-readonly" ], "env": { "GITHUB_TOKEN": "<GITHUB_TOKEN>" } } } }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Enable it
Cursor Settings → MCP → toggle the server on. Tools become available to the Composer/Agent.
How to install GitHub (read-only) in Codex CLIOpenAI coding agent
Add to ~/.codex/config.toml
toml[mcp_servers.github-mcp] command = "uvx" args = ["github-mcp-readonly"] env = { GITHUB_TOKEN = "<GITHUB_TOKEN>" }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Run Codex
Codex loads MCP servers from config.toml on startup and exposes their tools to the agent.
How to install GitHub (read-only) in WindsurfCodeium's agentic IDE
Edit ~/.codeium/windsurf/mcp_config.json
json{ "mcpServers": { "github-mcp": { "command": "uvx", "args": [ "github-mcp-readonly" ], "env": { "GITHUB_TOKEN": "<GITHUB_TOKEN>" } } } }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Reload
Windsurf → Cascade → refresh MCP servers. Cascade can now call the tools.
How to install GitHub (read-only) in ClineVS Code autonomous agent
Open Cline → MCP Servers → Configure
Adds to cline_mcp_settings.json.
Add the server
json{ "mcpServers": { "github-mcp": { "command": "uvx", "args": [ "github-mcp-readonly" ], "env": { "GITHUB_TOKEN": "<GITHUB_TOKEN>" } } } }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
How to install GitHub (read-only) in VS CodeCopilot / MCP support
Create .vscode/mcp.json
json{ "servers": { "github-mcp": { "type": "stdio", "command": "uvx", "args": [ "github-mcp-readonly" ], "env": { "GITHUB_TOKEN": "<GITHUB_TOKEN>" } } } }Fill in your credentials
Replace <GITHUB_TOKEN> with your real value. Keep secrets out of any config file you commit.
Start it
VS Code shows a ▶ Start action above the server entry. Agent mode (Copilot Chat) can then use the tools.
What does GitHub (read-only) need from you?
API key — Fine-grained GitHub token with read-only access (Metadata, Contents, Issues, Pull requests).
GITHUB_TOKENrequiredsecretEnvironment variableFine-grained GitHub token with read-only access (Metadata, Contents, Issues, Pull requests).
GITHUB_MCP_TOOLSEToptionalEnvironment variableTool descriptions to serve: v2 (default, optimized), v1 or v1b (benchmark baselines).
Pass secrets through your shell environment rather than committing them into a config file.
What tools does GitHub (read-only) expose? (3)
Taken from the project's README — the server itself was not queried, so check its docs for the exact schemas.
- server.pyRegisters tools, validates arguments, returns compact JSON with exact totals
- descriptions.pyVersioned descriptions (`v1` baseline, `v1b` ablation, `v2` optimized, or a JSON file)
- github_client.pyAuth, pagination, retries, rate limits, ETag cache, typed errors
What the code can do
Source analysis currently covers npm packages only. This server ships as a Python package, which needs a different parser.
Before you install
Signals gathered from the source repo and package registry — not a safety verdict.
What it can reach
- Runs code on your machine — Executes as a local process with your user's permissions, including filesystem access.
- Downloads at launch — The package is fetched from its registry each run unless you pin a version.
- Last commit 21 days ago — Actively maintained.
- Repository created 21 days ago — Very new project with little track record yet.
- 0 GitHub stars — Very little community usage so far.
Client compatibility
Health score
B · 76Maintenance, adoption, transparency and packaging — not a safety audit. How this is calculated
- Maintenance30%100%
Last commit 21 days ago.
- Adoption20%0%
0 stars.
- Transparency20%100%
4/4: ✓ public source repo, ✓ declared license, ✓ documentation, ✓ discoverable tool list.
- Provenance15%75%
Links to its own repository; package linkage unverified.
- Packaging15%100%
Publishes a pinned version (1.2.0).
Documentation
Full READMEGitHub MCP Server: Teaching an AI to Pick the Right Tool
A read-only Model Context Protocol server that lets Claude (or any MCP client) answer questions about my GitHub repos, issues, pull requests and commits. It comes with a benchmark that measures how often the model picks the right tool with the right arguments.
Rewriting the tool descriptions took a local 7B model from 63% to 95% correct, and from 60% to 90% on held-out questions it was never tuned on. An ablation shows where those 32 points came from, and most of them were not the prose:
| Change | Points | What it was | |---|---|---| | Accept bare repo names (mcp-bench-app, not only owner/mcp-bench-app) | +17 | input handling in the server | | Write the range (1-50) into the limit parameter's description | +8 | one parameter sentence | | Rewrite the tool descriptions (when to use, when NOT to, and the alternative) | +7 | the tool wording |
Every miss left in v2 is the model asking for something the API doesn't offer: merged PRs, sorting by stars, or closed issues from the open-issues tool. Better wording can't fix those. The next step is to support them in the schema.
[Explore every question in the results dashboard →](https://abdulmuhaiminkhan.github.io/github-mcp/)
What I built
- MCP server (Python, `mcp` SDK 2.x) with 6 read-only tools over stdio:
list_repositories,
get_repository, list_open_issues, search_issues, list_pull_requests, get_recent_commits.
- Least-privilege access: a fine-grained, read-only GitHub token and
readOnlyHintannotations.
The token stays in the server process and never reaches the model.
- Production behaviour: schema-validated inputs, retries with backoff and jitter, primary and
secondary rate-limit handling, ETag caching (304s don't count against the rate limit), exact totals for list tools, and error messages that tell the model how to recover.
- A benchmark with known answers: a seed script creates two repos with 15 issues, 5 pull requests
Excerpt — the full document is on GitHub.
Alternatives to GitHub (read-only)
- pare-githubA · 88Pare GitHub ג€” Structured GitHub operations (PRs, issues, actions) as typed JSON.
- GitHubB · 73GitHub via MCP: search, repos, issues, PRs, files, notifications. OAuth device flow or token.
- github-mcp-connectorB · 76MCP server for GitHub: repos, files, issues, PRs, search. Single Go binary.
- Robinson MCP for GitHubD · 23Operate GitHub from your AI assistant: repos, PRs, issues, Actions. Previews and read-only mode.
Maintain GitHub (read-only)? Add a badge to your README
Shows its health grade, and links readers to install steps for every client.
[](https://mcp-skills-hub.vercel.app/mcps/io-github-abdulmuhaiminkhan-github-mcp)Catalog data refreshed . Something wrong? Report it.