Skip to main content
MCP server CX Codex

Octocode MCP — Claude Code MCP server: code research

Searches and reads code in your local project and on GitHub: ripgrep, AST search, file trees, precise reads, LSP. Useful when an agent needs context before editing.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add octocode-mcp -e GITHUB_TOKEN=<GITHUB_TOKEN> -- npx -y octocode-mcp
Open on GitHub

What Octocode MCP - AI Context Platform does

Octocode is an MCP server for code research. One toolset covers local files and outside sources: GitHub repositories, pull requests, npm packages. A Rust engine keeps results compact so the model does not over-fetch tokens.

The agent picks what to ask for next: broad search first, then only the matched lines or region, with pagination and hints for the cheapest follow-up. Local paths go to local tools; owner/repo[/path] goes to GitHub. The same toolset runs as a CLI through npx octocode.

Node.js 20.12+ is required. A GitHub token is optional, but private repositories stay out of reach without it and API limits are lower. In a client config the token goes under env.

What it helps with

  • find where a function is called in the project
  • read through someone else's repo before forking it
  • trace which pull request introduced a pattern
  • gather context on a file before refactoring
  • look up usage examples for an npm package

Example prompts for the agent

  • Find every call to authenticate in the local project and show the lines.
  • Walk through the owner/repo repository and explain how auth works.
  • Show the schema for the localSearchCode tool.

How to install Octocode MCP - AI Context Platform

Platform CLI

claude mcp add octocode-mcp -e GITHUB_TOKEN=<GITHUB_TOKEN> -- npx -y octocode-mcp

Replace <…> with your own values

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about Octocode MCP - AI Context Platform

How do I install Octocode MCP in Claude Code?

Run claude mcp add octocode-mcp -e GITHUB_TOKEN=<GITHUB_TOKEN> -- npx -y octocode-mcp, replacing the token with your own.

What does Octocode MCP do?

It gives an agent tools to search and read code: ripgrep and AST search, file trees, precise reads, LSP. It works with local files as well as GitHub, PRs and npm.

Do I need a GitHub token?

No, but it unlocks private repositories and raises API limits. In a client config the token goes under env.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor