GitHub to MCP
Convert GitHub repositories to MCP servers automatically. Extract tools from OpenAPI, GraphQL & REST APIs for Claude Desktop, Cursor, Windsurf, Cline & VS Code. AI-powered code generation creates type-safe TypeScript/Python MCP servers. Zero config s
What is GitHub to MCP?
GitHub to MCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to convert github repositories to mcp servers automatically. extract tools from openapi, graphql & rest apis for claude desktop, cursor, windsurf, cline & vs code. ai-powered code generation creates type...
Convert GitHub repositories to MCP servers automatically. Extract tools from OpenAPI, GraphQL & REST APIs for Claude Desktop, Cursor, Windsurf, Cline & VS Code. AI-powered code generation creates type-safe TypeScript/Python MCP servers. Zero config s
This server falls under the Version Control category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Convert GitHub repositories to MCP servers automatically. Ex
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx github-toConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use GitHub to MCP
GitHub to MCP is a code-generation tool that converts any GitHub repository into a fully functional MCP server by automatically extracting tools from OpenAPI specs, GraphQL schemas, REST handlers, and README examples. It supports TypeScript, Python, and Go output and produces type-safe MCP servers that work immediately with Claude Desktop, Cursor, Windsurf, and VS Code. Developers use it to expose an existing API or codebase as an AI-callable tool set without writing any MCP boilerplate by hand.
Prerequisites
- Node.js 18 or later installed on your machine
- A GitHub account and optionally a personal access token (for higher API rate limits)
- The target GitHub repository must be public, or your token must have repo access
- An MCP client such as Claude Desktop, Cursor, or Windsurf
Run the converter with npx
Point the tool at any GitHub repository URL. It will analyse the repo, detect OpenAPI/GraphQL specs and framework routes, and generate an MCP server package in your current directory.
npx @nirholas/github-to-mcp https://github.com/owner/repoSet a GitHub token (optional but recommended)
Without a token the GitHub API rate limit is 60 requests per hour. Export a personal access token with repo or public_repo scope to raise it to 5,000 requests per hour.
export GITHUB_TOKEN=ghp_your_token_hereReview the generated server
The tool writes a self-contained MCP server file (e.g. server.mjs for TypeScript output) alongside a package.json or requirements.txt. Open the file to verify the extracted tools match your repository's API surface.
Install generated server dependencies
Move into the generated output directory and install dependencies before running the server.
cd generated-server && npm installAdd the server to your MCP client configuration
Register the generated server in your MCP client's config file. Use the absolute path to the generated server file and pass your GitHub token as an environment variable.
Restart your MCP client and verify tools
Reload Claude Desktop or your IDE. Ask the AI to list available tools — you should see the tools extracted from the repository such as get_readme, list_files, read_file, search_code, and any API-specific endpoints.
GitHub to MCP Examples
Client configuration
Claude Desktop config block using the generated server file. Replace the path with your actual generated output path.
{
"mcpServers": {
"my-repo": {
"command": "node",
"args": ["/absolute/path/to/generated-server/server.mjs"],
"env": {
"GITHUB_TOKEN": "ghp_your_token_here"
}
}
}
}Prompts to try
Example prompts to use once the generated MCP server is running in your AI client.
- "Convert https://github.com/stripe/stripe-openapi into an MCP server"
- "List all files in the repository root"
- "Read the contents of src/api/routes.ts"
- "Search the codebase for the string createPaymentIntent"
- "Call the GET /v1/balance endpoint from the Stripe API"Troubleshooting GitHub to MCP
Rate limit exceeded error during extraction
Set the GITHUB_TOKEN environment variable with a personal access token that has repo or public_repo scope. This raises the GitHub API limit from 60 to 5,000 requests per hour.
No tools are generated from the repository
The tool may not have found recognised spec files. Ensure the repo contains an OpenAPI spec (swagger.json, openapi.yaml), GraphQL schema (.graphql), or a documented REST API in the README. Use the --sources flag to explicitly specify extraction sources.
Generated server crashes on startup
Run npm install inside the generated directory before starting the server. If errors persist, check that Node.js 18 or later is installed with node --version.
Frequently Asked Questions about GitHub to MCP
What is GitHub to MCP?
GitHub to MCP is a Model Context Protocol (MCP) server that convert github repositories to mcp servers automatically. extract tools from openapi, graphql & rest apis for claude desktop, cursor, windsurf, cline & vs code. ai-powered code generation creates type-safe typescript/python mcp servers. zero config s It connects AI assistants to external tools and data sources through a standardized interface.
How do I install GitHub to MCP?
Follow the installation instructions on the GitHub to MCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with GitHub to MCP?
GitHub to MCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is GitHub to MCP free to use?
Yes, GitHub to MCP is open source and available under the Apache-2.0 license. You can use it freely in both personal and commercial projects.
GitHub to MCP Alternatives — Similar Version Control Servers
Looking for alternatives to GitHub to MCP? Here are other popular version control servers you can use with Claude, Cursor, and VS Code.
Ruiyu MA
★ 30.1kConnect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.
GitMCP
★ 8.1kTransforms any GitHub repository or GitHub Pages site into a documentation hub for AI assistants using the Model Context Protocol. It allows AI tools to access real-time code and documentation to prevent hallucinations and provide accurate API usage
GitHub Codemunch
★ 1.8kA token-efficient MCP server for exploring GitHub repositories using tree-sitter AST parsing to extract symbol signatures and summaries. It enables users to search and retrieve specific code components while significantly reducing token consumption c
Azure DevOps MCP Server
★ 1.7kThis server provides a convenient API for interacting with Azure DevOps services, enabling AI assistants and other tools to manage work items, code repositories, boards, sprints, and more. Built with the Model Context Protocol, it provides a standard
GitHub Official
★ 1.2kOfficial GitHub integration with comprehensive API coverage
Azure DevOps
★ 367Enables interaction with Azure DevOps through Cursor chat, providing tools to manage builds, pipelines, work items, sprints, and board operations. Supports secure authentication via Personal Access Tokens and allows natural language-driven DevOps tas
Browse More Version Control MCP Servers
Explore all version control servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up GitHub to MCP in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use GitHub to MCP?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.