Provides a single powerful interface to GitHub's GraphQL API, enabling comprehensive interaction with repositories, issues, pull requests, and other GitHub resources with smart abstractions for authentication and data handling.
Exposes GitHub's GraphQL API as the primary interface, allowing flexible querying and manipulation of GitHub data through GraphQL queries and mutations.
gh-mcp
Refined MCP server for GitHub GraphQL API.
If you haven't read the articleThe second wave of MCP: Building for LLMs, not developers by Vercel, I highly recommend checking it out to understand why we're building this project.
GitHub's official MCP Server exposes dozens of low-level tools that bloat token usage and are mostly impractical for LLMs. gh-mcp achieves the best of both worlds by providing a single, powerful interface: GitHub GraphQL, wrapped with smart abstractions.
This project does 3 things differently:
One powerful tool — exposes GraphQL instead of atomized endpoints. LLMs already understand GraphQL.
YAML output by default — makes nested data and file content readable without escaping.
Clean abstractions — handles authentication and low-level details. LLMs know how to use
--jqto filter.
Swapping in gh-mcp delivers better performance at lower cost for any GitHub interactions.
Installation
with uv:
MCP config:
If you prefer serving it via streamable-http:
This project requiresgh CLI to be installed and authenticated. Please follow the instructions at cli.github.com to set it up. And then you can login via gh auth login. Check that gh auth status works before using this MCP server.
Refined MCP server for GitHub GraphQL API.
GitHub's official MCP Server exposes dozens of low-level tools that bloat token usage and are mostly impractical for LLMs. gh-mcp achieves the best of both worlds by providing a single, powerful interface: GitHub GraphQL, wrapped with smart abstractions.