git-mcp-server
v2.15.3Comprehensive Git MCP server enabling native git tools including clone, commit, worktree, & more.
Values you need
| Variable | What it is | |
|---|---|---|
MCP_LOG_LEVEL | optional | Sets the minimum log level for output (e.g., 'debug', 'info', 'warn'). Default: info |
GIT_BASE_DIR | optional | Optional absolute path to restrict all git operations to a specific directory tree. Provides security sandboxing for multi-tenant or shared environments. |
npm (npx) verified
Requires Node.js 18+
Run in a terminal
claude mcp add git-mcp-server -- npx -y @cyanheads/git-mcp-server@2.15.3 run start:stdioAdd to
claude_desktop_config.json{
"mcpServers": {
"git-mcp-server": {
"args": [
"-y",
"@cyanheads/git-mcp-server@2.15.3",
"run",
"start:stdio"
],
"command": "npx"
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"git-mcp-server": {
"args": [
"-y",
"@cyanheads/git-mcp-server@2.15.3",
"run",
"start:stdio"
],
"command": "npx"
}
}
}Add to
.vscode/mcp.json{
"servers": {
"git-mcp-server": {
"args": [
"-y",
"@cyanheads/git-mcp-server@2.15.3",
"run",
"start:stdio"
],
"command": "npx",
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.git-mcp-server]
command = "npx"
args = ["-y", "@cyanheads/git-mcp-server@2.15.3", "run", "start:stdio"]For AI agents
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: git_add, git_blame, git_branch, git_changelog_analyze, git_checkout, git_cherry_pick, git_clean, git_clear_working_dir, ….
- If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.
Machine-readable: install.md · manifest.json