MCP Git Server
Reference MCP server that lets any LLM read, search, and manipulate local Git repositories.
Developers using Claude Desktop, Claude Code, VS Code, or Cursor who want the assistant to inspect diffs, walk history, stage files, and draft commits directly against a local Git repo.
Teams that need remote Git operations (push, PR review, issue triage) or hosted collaboration features - reach for the GitHub or GitLab MCP servers instead.
MCP Git Server (mcp-server-git) is a reference Model Context Protocol server, maintained inside the official modelcontextprotocol/servers repository, that exposes a local Git repository to any MCP-capable LLM host. Once wired into Claude Desktop, Claude Code, VS Code, Cursor, Zed, or your own agent runtime, the assistant can call a set of ~12 Git tools that mirror the everyday porcelain commands: git_status, git_diff_unstaged, git_diff_staged, git_diff (between refs), git_log with author/date filters, git_show, git_add, git_reset, git_commit, git_create_branch, git_checkout, and git_init. Each tool takes a repo_path argument, so the LLM operates against a working directory you point it at rather than a hosted service, which keeps the code, credentials, and .git metadata entirely on your machine or CI runner. The server is written in Python, installed via pip or uv (pip install mcp-server-git / uvx mcp-server-git), and wired into a client through a small JSON stanza in the host's MCP config. It is intentionally minimal: it does not push, pull, merge, or rebase; it does not talk to GitHub/GitLab APIs; and it does not manage remotes. That scope makes it a safe primitive to compose with heavier agent tooling such as a filesystem MCP server, a shell-execution server, or a platform-specific server like the GitHub MCP server for anything that has to leave the local repo. Typical workflows include letting Claude summarise unstaged changes before you commit, drafting a conventional-commit message from the staged diff, walking a bug back through git log and git show, opening a scratch branch for an experimental refactor, or blaming a regression across a range of commits during a code review. Because it is part of Anthropic's official reference set, it also doubles as a canonical example for developers learning how to build their own MCP servers.
This is the plumbing you want the moment an MCP client stops feeling useful for real coding work. It is deliberately boring - twelve Git verbs, local-only, MIT - and that is exactly why it belongs in almost every developer's MCP config alongside a filesystem server. Pair it with github-mcp-server when you also need to open PRs.
— The AI Tool Bible editorial team
Pros
- ✅ Official reference implementation maintained in the modelcontextprotocol/servers monorepo, so it tracks the spec closely and is a safe example to copy.
- ✅ Covers the everyday Git verbs an assistant actually needs (status, diff, log, show, add, reset, commit, branch, checkout, init) in one small binary.
- ✅ Runs fully local against a repo_path you control, so source code and .git history never leave your machine.
- ✅ Trivial to install (pip install mcp-server-git or uvx mcp-server-git) and to wire into Claude Desktop, VS Code, Cursor, or any MCP host with a few lines of JSON.
- ✅ MIT-licensed and open source, easy to fork if you want to add extra subcommands or tighten permissions.
- ✅ Composes cleanly with other MCP servers (filesystem, shell, GitHub) rather than trying to be a monolithic dev-agent.
Cons
- ⚠️ Scope is intentionally narrow: no push/pull/fetch, no merge, rebase, stash, cherry-pick, tag, or submodule support.
- ⚠️ Does not talk to GitHub/GitLab/Bitbucket APIs; PRs, issues, and code review still need a separate server such as github-mcp-server.
- ⚠️ Marked as early development in the README, so tool names and argument shapes can shift between releases.
- ⚠️ No built-in authorisation model - if the LLM can call git_commit or git_reset it can rewrite your working tree, so you rely on the host client's approval prompts.
- ⚠️ Python runtime requirement (uv/pip) is an extra dependency compared with the single-binary Go/Node MCP servers some teams prefer.
Use cases
Explore related
Compare with similar tools
All in MCP Servers →Airtable MCP Server
Model Context Protocol server that gives LLMs full read/write access to your Airtable bases.
Apple Notes MCP
Let Claude read your local Apple Notes over the Model Context Protocol.
AWS MCP Servers
Official AWS Labs collection of Model Context Protocol servers for connecting AI coding assistants and agents to AWS services and documentation.
Azure MCP Server
Official Microsoft MCP server that exposes 40+ Azure services to AI agents under the developer's own Entra ID credentials.
Blender MCP
Give Claude hands inside Blender — an MCP server for natural-language 3D modeling.
Brave Search MCP
Give any MCP client web and local search powered by the Brave Search API.