project-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@project-mcp search my-project for the authentication logic"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
project-mcp
A small, read-only MCP server that lets Claude read the source code of your projects. You keep your projects in one folder; Claude can then read the current version of your files instead of relying on pasted snippets.
The simple mental model
There is a
projects/folder.You create one sub-folder per project inside it.
Claude can read the code in those sub-folders. That's it.
project-mcp/
project_mcp.toml <- one line of config
projects/ <- you create this
some-project/ <- projectDrop a new folder into projects/ and it shows up automatically — no config
change needed.
Related MCP server: codebase-bridge-mcp
Setup
cd project-mcp
python3 -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
pip install -e .
mkdir projects # your projects live here
cp project_mcp.example.toml project_mcp.tomlThe default project_mcp.toml needs a single line:
projects_root = "projects"A relative path is resolved next to the config file, so this means "the
projects/ folder next to this config". Done.
MCP version note: this server pins
mcp>=1.2,<2. The official SDK is now at 2.0, which removed thefrom mcp.server.fastmcp import FastMCPimport that this server (and research-mcp) use. The pin keeps it working and consistent with research-mcp.
Connect it to Claude Desktop
Add an entry to claude_desktop_config.json. Using the venv's Python by
absolute path is the most robust:
{
"mcpServers": {
"project-mcp": {
"command": "/absolute/path/to/project-mcp/.venv/bin/python",
"args": ["-m", "project_mcp"],
"env": {
"PROJECT_MCP_CONFIG": "/absolute/path/to/project-mcp/project_mcp.toml"
}
}
}
}(On Windows use ...\.venv\Scripts\python.exe.) Restart Claude Desktop;
project-mcp then appears next to research-mcp in the tool list. A good
first check: ask Claude to run list_projects.
Tools (all read-only)
Tool | Purpose |
| the projects Claude can see + how many readable files each has |
| readable files in a project (exclusions already applied) |
| read one file |
| substring search across readable files |
No writing, no deleting — for "review my code" reading is enough and much safer.
Security model
The config is the policy, and it is enforced in code — the server cannot read anything the policy forbids, regardless of what a request says. Two boundaries are checked, in order:
The named project must be visible (either auto-discovered under
projects_root, or on theinclude_projectsallow-list if you set one).The file must resolve to a path inside that project (containment is checked after
Path.resolve(), so..segments and symlinks are collapsed first and then rejected), must not sit in an excluded directory, must have an allowed suffix, and must not match an excluded glob (e.g..env,*secret*).
By default any folder you place in projects/ is readable. If you want tighter
control — say you keep NDA/company code around — set include_projects to an
explicit allow-list so a project is only visible when you name it on purpose.
Either way, the secret-file exclusions (.env, *.key, *secret*, …) always
apply.
Tests
pytest # 13 tests, focused on path confinement:
# .. escapes, symlink escape, allow-list, exclusions, suffixes,
# and auto-discoveryProject structure
project-mcp/
project_mcp.example.toml config template
pyproject.toml
src/project_mcp/
config.py load config (projects_root, optional allow-list, exclusions)
safe_io.py security core: safe_resolve + read / list / search
server.py FastMCP server + the four tools
tests/test_safe_io.pyAvailable Tools
4 toolslist_filesA
Lists the readable source files inside one project.
Excluded directories (e.g. .git, .venv) and excluded patterns (e.g. secrets, .env files) are already filtered out - what you see here is exactly what read_code is allowed to open.
Args: project: A project name from list_projects, e.g. "conftransform".
Inputs: project (required). Returns: result
list_projectsA
Lists the projects you have made visible to project-mcp.
Each entry shows the project name, whether its folder currently exists, and how many readable source files it contains. Start here to see what is available before reading or searching.
Inputs: no named parameters. Returns: result
read_codeA
Reads the current content of one source file in a project.
Use this to see the up-to-date version of a file instead of relying on a pasted copy. Only files inside an allow-listed project, of an allowed type, and outside the excluded directories/patterns can be read.
Args: project: Project name, e.g. "conftransform". path: Project-relative path, e.g. "src/conftransform/levels.py". max_chars: Maximum number of characters to return.
Inputs: path (required), project (required), max_chars.
search_codeA
Searches for a plain-text substring across readable project files.
Case-insensitive. Returns matching locations as {project, path, line, text}. Use it to locate where something is defined or used without having to open files one by one.
Args: query: Text to look for, e.g. "SecurityLevel" or "def safe_resolve". project: Optional - restrict the search to a single project. max_results: Cap on the number of matches returned.
Inputs: query (required), project, max_results. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Each tool targets a distinct action and resource: listing projects, listing files, reading a file, and searching code. No overlap or ambiguity between them.
All tool names follow a consistent verb_noun pattern: list_projects, list_files, read_code, search_code. The style is uniform and predictable.
With 4 tools, the set is well-scoped for a read-only code exploration server. Each tool serves a necessary function and there is no bloat.
The toolset covers the full workflow of browsing projects: discover projects, list their files, read file contents, and search across them. No significant gaps for the intended domain.
Maintenance
Related MCP Connectors
Shared memory MCP server for Claude Code, Codex, Gemini CLI and Cursor. Cited, editable.
Augments MCP Server - A comprehensive framework documentation provider for Claude Code
An MCP server that gives your AI access to the source code and docs of all public github repos
Agent-native MCP server over the public saagarpatel.dev corpus. Read-only, stateless.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA secure MCP server that allows Claude to read and write local files on your machine with explicit approval gating for each access.MIT
- AlicenseAqualityDmaintenanceA read-only MCP server that lets a Claude chat explore your local repository and answer questions about it, returning synthesized answers with file:line references.31MIT
- AlicenseBqualityDmaintenanceA read-only MCP server that exposes a local code workspace to AI clients via stdio, providing file browsing and text search capabilities with path safety rules.1MIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server that indexes local code repositories, extracting symbols and call graphs to give Claude precise, structural answers with real file paths and line numbers. Runs entirely locally with no network requests, for privacy-focused code understanding.1,717 npmMIT