
modelcontextprotocol/server-git
Read, search and analyze local Git repositories
by modelcontextprotocolFree
Description
Git is a Model Context Protocol server, written in Python, that lets a language model read, search and analyze a local Git repository, and make some changes to it. It provides a set of tools for repository work, including git_show, which displays a commit or the contents of a file or directory at a revision, and git_branch, which lists local, remote or all branches and can filter them by whether they contain or do not contain a commit. The repository path given with --repository can be any path inside a Git working tree. At startup the server walks up to the enclosing repository root, so a shared configuration launched from any subfolder still works, but a path inside the repository allows tool calls anywhere in that repository and not only under the folder you named. A path that does not exist or is outside a repository is logged as an error at startup. The server installs with uv, which the README recommends, or with pip, and it can be used from Claude Desktop with uvx, Docker or pip, and from VS Code through a user or workspace MCP configuration. Docker needs the repository folder mounted with the path replaced by your own. It requires the MCP Python SDK version 1.x. Source is in the modelcontextprotocol servers repository.…
Highlights
- Reads, searches and analyzes local Git repositories
- git_show for commits, files and directories at a revision
- git_branch lists local, remote or all branches with filters
- Repository path can be any path inside a working tree
Ratings & Reviews
No ratings yet
Be the first to rate modelcontextprotocol/server-git.
People also visit
modelcontextprotocol/server-git FAQ
What can it do with a repository?
Read, search and analyze it, including showing commits and files at a revision and listing branches, plus tools for history, diffs and status.
Which path should I pass?
Any path inside the Git working tree. The server walks up to the repository root, so the whole repository is allowed, not only the folder you named.
How do I install it?
The README recommends uv, which runs mcp-server-git with uvx. pip and Docker are described as well.
What does it need?
The MCP Python SDK version 1.x, and a local Git repository.
What are the best modelcontextprotocol/server-git alternatives?
Popular alternatives to modelcontextprotocol/server-git include github, mcporter and caveman-commit. See all modelcontextprotocol/server-git alternatives












