GitMCP is a free, open-source Model Context Protocol (MCP) server that transforms any GitHub project into a documentation hub for AI tools. It enables AI assistants like Cursor to access up-to-date documentation and code directly from GitHub repositories, eliminating code hallucinations and providing accurate information even for libraries the AI hasn't encountered before.
Select one of these URL formats based on what you want to connect to:
gitmcp.io/{owner}/{repo}{owner}.gitmcp.io/{repo}gitmcp.io/docsReplace {owner} with the GitHub username or organization, and {repo} with the repository name.
Update your Cursor configuration file at ~/.cursor/mcp.json:
{
"mcpServers": {
"gitmcp": {
"url": "https://gitmcp.io/{owner}/{repo}"
}
}
}
In Claude Desktop, go to Settings > Developer > Edit Config and use:
{
"mcpServers": {
"gitmcp": {
"command": "npx",
"args": [
"mcp-remote",
"https://gitmcp.io/{owner}/{repo}"
]
}
}
}
Update your Windsurf configuration file at ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"gitmcp": {
"serverUrl": "https://gitmcp.io/{owner}/{repo}"
}
}
}
Update your VSCode configuration file at .vscode/mcp.json:
{
"servers": {
"gitmcp": {
"type": "sse",
"url": "https://gitmcp.io/{owner}/{repo}"
}
}
}
Update your Cline configuration file at ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json:
{
"mcpServers": {
"gitmcp": {
"url": "https://gitmcp.io/{owner}/{repo}",
"disabled": false,
"autoApprove": []
}
}
}
Plugin name: gitmcp
SSE URL: https://gitmcp.io/{owner}/{repo}
Add a new MCP server with the following configuration:
{
"mcpServers": {
"git-mcp Docs": {
"command": "npx",
"args": [
"mcp-remote",
"https://gitmcp.io/{owner}/{repo}"
]
}
}
}
{
"mcpServers": {
"git-mcp Docs": {
"command": "npx",
"args": [
"mcp-remote",
"https://gitmcp.io/{owner}/{repo}"
]
}
}
}
GitMCP connects your AI assistant to GitHub repositories using the Model Context Protocol, allowing your AI to access additional information when needed:
GitMCP provides several tools to AI assistants:
fetch_<repo-name>_documentation: Gets the primary documentation from a repositorysearch_<repo-name>_documentation: Searches through documentation with specific queriesfetch_url_content: Retrieves content from links mentioned in documentationsearch_<repo-name>_code: Searches through code in the repositoryFor the GitHub repository https://github.com/microsoft/playwright-mcp, add https://gitmcp.io/microsoft/playwright-mcp as an MCP server to Windsurf.
Prompt to Claude:
"How do I use the Playwright MCP"
For the GitHub Pages site langchain-ai.github.io/langgraph, add https://langchain-ai.gitmcp.io/langgraph as an MCP server to Cursor.
Prompt to Cursor:
"Add memory to my LangGraph agent"
The generic gitmcp.io/docs endpoint allows AI to pick the GitHub project dynamically.
Prompt to any AI assistant:
"I want to learn about the OpenAI Whisper speech recognition model. Explain how it works."
Add this to your README.md to showcase your documentation access through GitMCP:
[](https://gitmcp.io/OWNER/REPO)
Replace OWNER with your GitHub username or organization, and REPO with your repository name.
To add this MCP server to Claude Code, run this command in your terminal:
claude mcp add-json "gitmcp" '{"url":"https://gitmcp.io/{owner}/{repo}"}'
See the official Claude Code MCP documentation for more details.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.
To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".
When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:
{
"mcpServers": {
"gitmcp": {
"url": "https://gitmcp.io/{owner}/{repo}"
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.
To add this MCP server to Claude Desktop:
1. Find your configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.json~/.config/Claude/claude_desktop_config.json2. Add this to your configuration file:
{
"mcpServers": {
"gitmcp": {
"url": "https://gitmcp.io/{owner}/{repo}"
}
}
}
3. Restart Claude Desktop for the changes to take effect