MCP.so
Sign In

MCP Git Explorer

@jmiedzinski

About MCP Git Explorer

Simple MCP server for fetching the remote git repository content as a structured text file

Config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "mcp-git-explorer": {
      "command": "uv",
      "args": [
        "pip",
        "install",
        "mcp-git-explorer"
      ]
    }
  }
}

Tools

No tools detected

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is MCP Git Explorer?

MCP Git Explorer is a Model Context Protocol (MCP) server that clones remote Git repositories and returns their contents as a structured text file. It is designed for AI assistants like Claude, allowing them to explore repository structure, estimate codebase size and token count, and access file contents without manual downloading.

How to use MCP Git Explorer?

Install via pip install mcp-git-explorer or uv pip install mcp-git-explorer. Run directly with mcp-git-explorer (or uvx mcp-git-explorer). Optionally pass --transport sse for SSE transport or --gitlab-token YOUR_TOKEN for private GitLab repositories. In Claude, the server provides three tools: get_codebase, estimate_codebase, and check_gitlab_token_status.

Key features of MCP Git Explorer

  • Clones and analyzes Git repositories from remote URLs.
  • Generates a structured text representation of all file contents.
  • Estimates codebase size and token count without full download.
  • Supports public repositories and private GitLab repositories via token authentication.
  • Token counting using OpenAI’s tiktoken library.
  • Respects .gitignore and .repomixignore patterns; skips binary and empty text files.

Use cases of MCP Git Explorer

  • Quickly assess repository size before deciding to retrieve full content.
  • Enable Claude to browse and analyze code from any public Git repository.
  • Access private GitLab repositories with a personal access token.
  • Automatically generate a token-aware summary of a codebase.
  • Integrate repository exploration into AI‑powered coding workflows.

FAQ from MCP Git Explorer

What types of Git repositories are supported?

Public repositories on any Git hosting service, plus private GitLab repositories when a personal access token is provided via --gitlab-token or the GIT_EXPLORER_GITLAB_TOKEN environment variable.

How do I authenticate to private GitLab repositories?

Provide a GitLab personal access token either as the --gitlab-token CLI argument or set the GIT_EXPLORER_GITLAB_TOKEN environment variable. Use the check_gitlab_token_status tool to confirm it is configured.

What does the estimate_codebase tool return?

It returns repository statistics: file count, directory structure, and a token estimation (using OpenAI’s tiktoken) without downloading all file contents.

Can I control whether file contents are included when using get_codebase?

Yes. The use_token parameter (default True) controls token counting behavior. When True, the response includes token counts; set to False to skip token estimation.

Is there any file filtering or size limit?

The server respects .gitignore and .repomixignore patterns, skips binary files and empty text files to keep the output concise and relevant.

Frequently asked questions

What types of Git repositories are supported?

Public repositories on any Git hosting service, plus private GitLab repositories when a personal access token is provided via `--gitlab-token` or the `GIT_EXPLORER_GITLAB_TOKEN` environment variable.

How do I authenticate to private GitLab repositories?

Provide a GitLab personal access token either as the `--gitlab-token` CLI argument or set the `GIT_EXPLORER_GITLAB_TOKEN` environment variable. Use the `check_gitlab_token_status` tool to confirm it is configured.

What does the `estimate_codebase` tool return?

It returns repository statistics: file count, directory structure, and a token estimation (using OpenAI’s tiktoken) without downloading all file contents.

Can I control whether file contents are included when using `get_codebase`?

Yes. The `use_token` parameter (default `True`) controls token counting behavior. When `True`, the response includes token counts; set to `False` to skip token estimation.

Is there any file filtering or size limit?

The server respects `.gitignore` and `.repomixignore` patterns, skips binary files and empty text files to keep the output concise and relevant.

Comments

More Version Control MCP servers