
bgauryy Octocode MCP server
Lets your AI assistant research code across GitHub, npm and your local projects with search, reads and symbol navigation.
Octocode runs on your machine and gives your assistant code research tools. It searches GitHub and npm, and reads your local projects, with precise file slices and language-server lookups.
A GitHub token is optional. It unlocks private repos and higher limits. By default it can read files under your home folder, so check what your client may open.
Good for
- Developers who want an agent to study unfamiliar repos before changing code
- Teams exploring dependencies and open-source code on GitHub
- Anyone who wants fewer wasted tokens on code reads
Works in
12 should work
Tap an app to see how to set it up and any known problems.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Supports local MCP servers.
Client does not support this transport.
Client does not support this transport.
Install Octocode MCP - AI Context Platform
Claude Code
- 1
Copy this prompt.
Add the Octocode MCP - AI Context Platform server to Claude Code. Run this command: claude mcp add-json octocode --scope user '{"command":"npx","type":"stdio","args":["octocode-mcp@latest"]}' Then check that it loaded and tell me if I need to sign in or restart. - 2
Paste it into Claude Code. It shows the change and asks before running it.
Requires Node.js, Node.js 22.22.2+, 24.15+ or 26+.
Node.js 22.22.2 or later in the 22 line, 24.15 or later, or 26 and up is required. A GitHub token is optional: it unlocks private repos and higher rate limits. Sign in with npx octocode auth login, use the GitHub CLI (gh auth login), or set GITHUB_TOKEN in the config env.
From the project README. Source.
Tools
Searches GitHub code, repos and trees
Finds code, repositories or a repository's file tree on GitHub. One call can carry up to five parallel searches, and each picks its type with an operation field.
Try: “Find repos that implement an OAuth device flow in Go.”
Network ·
ghSearchReads a file from GitHub
Reads a GitHub file as a whole, a line range, matching slices around a string, or in pages. It strips comments and blanks by default to save tokens.
Try: “Show me lines 40 to 120 of src/auth.ts in vercel/next.js.”
Network ·
ghGetFileContentSearches PRs, issues and commits
Lists or searches pull requests, issues or commits in a repo, one operation per query.
Try: “Find merged PRs that touched the auth middleware in this repo.”
Network ·
ghSearchHistoryReads one PR, issue, commit or comparison
Returns one pull request, issue or commit in detail, or compares two refs with ahead and behind counts.
Try: “Show PR 4821 with its changed files and review comments.”
Network ·
ghGetHistoryItemFinds npm packages and their repos
Looks up npm packages by keyword and returns metadata plus the source repository so the assistant can move on to GitHub.
Try: “Which npm package parses cron expressions, and where is its repo?”
Network ·
npmSearchSearches your local code
Searches your files by text, code structure, file names or directory tree. Matches come back with paths and line numbers.
Try: “Find where authenticate is defined in this project.”
Files ·
localSearchReads a local file
Reads a local file as an exact slice, a matching string, a line range or in pages, within the folders it is allowed to read.
Try: “Show me the first 80 lines of src/server.ts.”
Files ·
localGetFileContentMaps file dependencies
Analyzes how files depend on each other, and reports paths, circular dependencies and candidates for dead code.
Try: “Are there circular imports in this project?”
Files ·
localAnalyzeGraphNavigates code like an editor
Uses language servers for definitions, references, callers, callees, hover info, symbols and type checks.
Try: “Find all callers of handleLogin.”
Runs code ·
lspGetSemantics
Read from the source code
Permissions
medium risk · 5 things to watch
Medium risk
It only reads, but it can read any file under your home folder that is not on its sensitive-file blocklist, and private GitHub repos when you give it a token. Use a token limited to the repos you need, and set WORKSPACE_ROOT and ALLOWED_PATHS if you want it confined to one project.
What it can do
- Read your data
- Create and change things
- Delete things
- Read-only modeHow to turn it on
Watch out for
It can read files across your home folder
Local reads are bounded to your home folder by default, not just the open project. Known secret files such as .env and .aws are blocked, and content is scanned for secrets. ALLOWED_PATHS only adds folders on top of home; the only documented way to shut local reads off is ENABLE_LOCAL=false (or DISABLE_TOOLS for single tools). github.com
A GitHub token may unlock private repos
The token scopes the README lists are repo, read:user and read:org. Use a fine-grained token limited to the repos you want researched. github.com
It reuses your GitHub CLI login
With no token set, it calls `gh auth token` and uses what the GitHub CLI holds. Sign out of gh or set a token if you do not want that. github.com
It keeps a cache on disk
API responses, sessions and cloned files go under ~/.octocode/tmp by default. Set OCTOCODE_STORAGE_MODE=memory to avoid persistent storage. github.com
Cloning repositories is opt-in
ghCloneRepo and directory fetches stay off until you set ENABLE_CLONE=true. They write a local copy of a repo. github.com
Security advisories
No published security advisories as of Nov 1, 2026.
Technical details
| Turning on read-only | The nine default tools are read-only (readOnlyHint is true). Cloning repositories is a tenth tool that stays off unless ENABLE_CLONE is set. Set OCTOCODE_STORAGE_MODE=memory to stop disk caches. |
|---|---|
| Talks to | api.github.com. registry.npmjs.org |
| Scopes |
|
Questions
Is the bgauryy Octocode MCP server official?
No. It is a community project by bgauryy (the bgauryy/octocode repo and the octocode-mcp npm package), not made by GitHub or npm. It is a different product from the Rust Octocode indexer by muvon. The README calls it a community server for the Model Context Protocol.
Do I need a GitHub token?
No. Everything is optional, and public repos work without one. A token, a gh CLI login or npx octocode auth login unlocks private repos and higher rate limits. The token scopes are repo, read:user and read:org.
Can it run read-only?
Yes. The nine default tools only read. Cloning repos is a separate opt-in tool and stays off unless you set ENABLE_CLONE=true.
Can it read my local files?
Yes. Local tools are on by default and reach your home folder, minus a blocklist of secret files such as .env, .aws and .git. Set ENABLE_LOCAL=false to turn them off.
Does it send my code to a server?
Octocode runs on your machine and calls the GitHub and npm APIs. What the assistant reads goes to your AI service, after the tool scans it for secrets and masks them.
Which Node.js version does it need?
Node.js 22.22.2 or later in the 22 line, 24.15 or later, or 26 and up.
Does it work with GitHub Enterprise?
Yes. Set GITHUB_API_URL to your Enterprise API address in the config env.
How is this different from the GitHub MCP server?
GitHub's own server is the official one for managing repos, issues and PRs. Octocode is built for reading and researching code across GitHub, npm and local files with fewer tokens.
Information
updated Nov 2, 2026
- Publisher
- Community
- Package
octocode-mcp- Registry
- npm
- Transport
- stdio
- Auth
- token in env
- Version
- 19.1.0
- License
- MIT
- Last commit
- Oct 30, 2026
- Open issues
- 5
- Listed in
- Official MCP registry
Sources
Docs, issue trackers and discussions this page is built from. Issues, quotes and findings above link to their own source.
Show all 3Hide
- octocode-mcp README (npm 19.1.0) · github.com
- Octocode configuration · github.com
- Octocode security · github.com