/ Directory / Playground / GitMCP
● Community idosal ⚡ Instant

GitMCP

by idosal · idosal/git-mcp

Turn any public GitHub repo into a live MCP endpoint — pull its README, code, and docs into Claude without cloning or hallucinating APIs.

GitMCP hosts a remote MCP server at gitmcp.io/{owner}/{repo}. Claude gets tools to fetch documentation, search the repo, list files, and read specific paths — always against the current main branch. Removes the "Claude made up a function that doesn't exist" class of errors when using unfamiliar libraries.

Why use it

Key features

Live Demo

What it looks like in practice

git-mcp-idosal.replay ▶ ready
0/0

Install

Pick your client

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "git-mcp-idosal": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://gitmcp.io/{owner}/{repo}"
      ]
    }
  }
}

Open Claude Desktop → Settings → Developer → Edit Config. Restart after saving.

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "git-mcp-idosal": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://gitmcp.io/{owner}/{repo}"
      ]
    }
  }
}

Cursor uses the same mcpServers schema as Claude Desktop. Project config wins over global.

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "git-mcp-idosal": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://gitmcp.io/{owner}/{repo}"
      ]
    }
  }
}

Click the MCP Servers icon in the Cline sidebar, then "Edit Configuration".

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "git-mcp-idosal": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://gitmcp.io/{owner}/{repo}"
      ]
    }
  }
}

Same shape as Claude Desktop. Restart Windsurf to pick up changes.

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "git-mcp-idosal",
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://gitmcp.io/{owner}/{repo}"
      ]
    }
  ]
}

Continue uses an array of server objects rather than a map.

~/.config/zed/settings.json
{
  "context_servers": {
    "git-mcp-idosal": {
      "command": {
        "path": "npx",
        "args": [
          "-y",
          "mcp-remote",
          "https://gitmcp.io/{owner}/{repo}"
        ]
      }
    }
  }
}

Add to context_servers. Zed hot-reloads on save.

claude mcp add git-mcp-idosal -- npx -y mcp-remote https://gitmcp.io/{owner}/{repo}

One-liner. Verify with claude mcp list. Remove with claude mcp remove.

Use Cases

Real-world ways to use GitMCP

How to stop Claude hallucinating APIs for a library it half-knows

👤 Devs using newer libraries (post-cutoff) or niche SDKs ⏱ ~15 min beginner

When to use: You're integrating a library and Claude keeps inventing method names that don't exist.

Prerequisites
  • Know the library's GitHub path — e.g. pydantic/pydantic-ai — paste the owner/repo into gitmcp.io
Flow
  1. Add GitMCP pointed at the library
    Add the GitMCP server for pydantic/pydantic-ai to my config, then list the top-level docs files.✓ Copied
    → Tool returns README.md plus /docs tree — no fabricated paths
  2. Ask against real source
    Using the GitMCP for pydantic-ai, show me the actual constructor signature for Agent — quote it from source, don't summarize.✓ Copied
    → Exact signature with source file + line ref
  3. Verify by running
    Write a minimal runnable example using only what you saw in the repo. If something is missing, say so — don't guess.✓ Copied
    → Example compiles; Claude flags any missing pieces

Outcome: Working integration that matches the library's actual API, not a plausible-sounding fiction.

Pitfalls
  • Library is in a monorepo subdirectory — Use the tree tool first to find the right package root before reading
Combine with: context7 · github

Quick-audit an unfamiliar open source repo before forking

👤 Engineers evaluating dependencies ⏱ ~10 min beginner

When to use: You're about to adopt a library and want to know what you're getting into without cloning.

Flow
  1. Overview
    Use GitMCP for owner/repo. Summarize the architecture from README + top-level directories in 8 lines.✓ Copied
    → Concrete directory-anchored summary, not marketing fluff
  2. Risk scan
    Pull the package manifest and list every dependency. Flag any that look abandoned or have known CVE history.✓ Copied
    → Dependency table with per-item assessment
  3. Fit check
    Is there a plugin/extension API I can use, or would I need to fork? Cite the code.✓ Copied
    → Code-anchored answer with file paths

Outcome: A 5-minute fork/adopt/skip decision backed by actual repo content.

Pitfalls
  • Private repo without token — Use the self-hosted Docker image and set GITHUB_TOKEN
Combine with: github

Combinations

Pair with other MCPs for X10 leverage

git-mcp-idosal + context7

Stack two layers of up-to-date docs — Context7 for official SDK docs, GitMCP for the repo source

Compare what context7 says about Foo.bar() with the actual source via GitMCP. Any drift?✓ Copied
git-mcp-idosal + github

Use GitMCP for read-only docs and GitHub MCP for PR/issue creation

Read the contribution guide via GitMCP, then open a well-formed PR via GitHub MCP.✓ Copied

Tools

What this MCP exposes

ToolInputsWhen to callCost
fetch_documentation owner, repo First call when exploring an unfamiliar repo 1 GitHub API call
search_documentation owner, repo, query: str Find doc sections mentioning a specific concept 1 API call
fetch_url_content url: str Pull specific file by raw URL free
search_code owner, repo, query: str Find where a symbol is defined or used 1 API call

Cost & Limits

What this costs to run

API quota
GitHub unauthenticated: 60 req/h per IP. Authenticated: 5000 req/h.
Tokens per call
500–5000 depending on file
Monetary
Free (hosted)
Tip
Use search_* tools instead of dumping whole files

Security

Permissions, secrets, blast radius

Minimum scopes: public_repo (for private access)
Credential storage: Token as env var in self-hosted mode
Data egress: gitmcp.io (hosted) or your own instance
Never grant: repo:write

Troubleshooting

Common errors and fixes

403 rate limit exceeded

Self-host with a PAT, or wait — unauth limit is 60 req/h

Verify: Check X-RateLimit-Remaining header
Repo not found

Check owner/repo spelling and that it's public. For private, use self-hosted image.

Returns truncated content

GitHub API caps raw blob at 1MB. Use search_code for large files.

Alternatives

GitMCP vs others

AlternativeWhen to use it insteadTradeoff
Context7You want a curated library-docs surface rather than raw repoContext7 only indexes a subset; GitMCP covers any public repo
GitHub MCP (official)You need PR/issue/write operations tooGitHub MCP is write-capable (more to lock down); GitMCP is read-only

More

Resources

📖 Read the official README on GitHub

🐙 Browse open issues

🔍 Browse all 400+ MCP servers and Skills