Github Repo MCP logo

Github Repo MCP

by ryan0204

Browse public GitHub repositories, inspect directories, and retrieve code or text files through MCP tools.

Install Github Repo MCP

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "ryan0204-github-repo-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "github-repo-mcp"
      ],
      "env": {
        "GITHUB_TOKEN": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

We couldn’t confirm it starts correctly

The install command started, but didn't respond the way we expected when we tried to talk to it.

npx -y github-repo-mcp

initialize succeeded but no response to tools/list.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked 19d ago.

Overview

ryan0204/github-repo-mcp MCP server gives AI assistants read-only access to public GitHub repository structures and file contents. It runs as a stdio process and exposes tools for listing repository roots, inspecting directory paths, and retrieving individual files through the GitHub API. Use it when an assistant needs to examine a repository without cloning it; an optional GitHub token raises API rate limits.

Use cases

  • Inspect a repository's root structure
  • Explore source directories without cloning
  • Read README and code files
  • Review a public repository through an AI assistant

Key features

  • List repository root contents
  • List files in a directory
  • Retrieve code and text files
  • Optional GitHub token support
  • stdio MCP client compatibility

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 1d ago

Recent health check succeeded.

10/14 checks healthy over the last 79d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 11d ago via OSV.dev · github-repo-mcp (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars33Stargazers on the source repository.
npm downloads254Package downloads in the last 30 days.
Last commit1mo agoMost recent push to the default branch.
Install checkInconclusiveStarted but did not complete the MCP handshake in our test.
Directory activity2 viewsConfig copies, upvotes, and views on AllMCPs.

How Github Repo MCP works

What ryan0204/github-repo-mcp does

The ryan0204/github-repo-mcp MCP server lets an MCP-compatible assistant inspect GitHub repositories through the GitHub API. Its supported operations are focused on repository navigation and reading: listing entries at a repository root, listing entries within a chosen directory, and returning the contents of a selected code or text file.

Requests use a GitHub repository URL plus, where applicable, a path. The server is intended for examining repository structure and source files from an assistant conversation. It does not document operations for editing files, creating issues, making commits, or accessing other GitHub resources.

How it works

The package runs as a command-line MCP process using the stdio protocol. An MCP client starts the process and communicates with it through standard input and output. The assistant can then call one of the repository tools with a GitHub URL and path values.

The ryan0204/github-repo-mcp MCP server provides these tools:

  • getRepoAllDirectories lists files and directories at the repository root. It accepts repoUrl.
  • getRepoDirectories lists the contents of a specified directory. It accepts repoUrl and path, such as src.
  • getRepoFile retrieves a selected file. It accepts repoUrl and path, such as src/index.js.

These operations are useful for questions such as locating a project entry point, checking a directory layout, or reading a README and source file without first downloading the repository locally.

Setup and configuration

The ryan0204/github-repo-mcp MCP server requires Node.js 18 or newer and npm or Yarn. It can be launched with npx github-repo-mcp on macOS, or with the Windows command shown in the project instructions. It can also be installed through Smithery for Claude Desktop or added to an IDE's MCP configuration.

The only documented environment variable is GITHUB_TOKEN. It is optional. Without it, requests use unauthenticated GitHub API access and are subject to lower rate limits. Supplying a personal access token increases the available rate limit and may permit access to private repositories when the token has suitable permissions.

Limitations and notes

Unauthenticated GitHub API requests are limited to 60 requests per hour according to the project documentation. Configure GITHUB_TOKEN if an assistant makes enough requests to reach that limit.

Public repositories are supported without authentication. Private repository access depends on providing a token with appropriate permissions; the documentation does not describe private access as available without one.

Binary files are detected by common file extensions and are not displayed. GitHub API file-size restrictions can also prevent retrieval of large files. Network or GitHub API availability can affect requests, so connection failures should be checked against the local internet connection and GitHub API status.

The package is documented as compatible with Cursor, Windsurf, Claude Desktop, and other MCP clients that support stdio. Its documented capabilities are read-only repository browsing and file retrieval, not repository mutation.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Github Repo MCP

ryan0204/github-repo-mcp is an MCP server that connects AI assistants to GitHub's repository API for reading public repository structure and file content. Its main tools list root entries, inspect a directory path, and retrieve a specific file. It runs over stdio and supports an optional GitHub token for higher API limits.

Install it with Node.js 18 or newer using `npx github-repo-mcp`, or configure the command in an MCP client.

Yes, ryan0204/github-repo-mcp works with Cursor because it supports MCP clients using the stdio protocol. The README includes `.cursor/mcp.json` examples, including Windows configurations that invoke NPX through WSL.

Use a GitHub personal access token with appropriate permissions by setting `GITHUB_TOKEN` in the MCP client configuration. The server works without authentication for public repositories, while private repository access depends on the token's permissions.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewGithub Repo MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/ryan0204-github-repo-mcp?style=directory)](https://allmcps.com/mcp/ryan0204-github-repo-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/ryan0204-github-repo-mcp"><img src="https://allmcps.com/api/badge/ryan0204-github-repo-mcp?style=directory" alt="Github Repo MCP on AllMCPs" /></a>