Quick install
Use
-s user to install for your user (available across all projects) or -s project to commit a .mcp.json to the repo so teammates get it automatically. Default is local (this project, your machine).Verify
sharc entry. From inside Claude Code, ask:
index_codebase, search_code, clear_index, get_indexing_status, start_watch, stop_watch, get_watch_status.
Manual configuration (alternative)
If you’d rather edit JSON directly, add this to your Claude Code MCP config:Usage examples
Indexing a codebase
Searching code
Incremental updates
After the initial index, SHARC watches the working tree and re-indexes changed files automatically:Best practices
Index before deep dives
For the best experience, index before asking complex questions:Use natural language queries
SHARC understands semantic meaning, not just keywords:Adjust result limits
For broad exploration, increase the limit:Troubleshooting
Tools not available
- Restart Claude Code
- Run
claude mcp listand confirmsharcis listed - Verify the API key is correct:
claude mcp get sharc
Slow indexing
Initial indexing time depends on codebase size. The Hono repo takes ~30-45 seconds; large repos like Next.js can take 3-4 minutes. Subsequent runs use Merkle diff for near-instant updates.Search returns unexpected results
- Try rephrasing your query semantically
- Use
extensionFilterto narrow to specific file types - Check if the codebase is fully indexed with
get_indexing_status