Local document search over your folders: hybrid keyword+semantic, fully offline, read-only
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Chat with your folders. A local document search MCP server β your files never leave your machine.
docsonar indexes folders of documents into a single SQLite database and gives any MCP client (Claude Desktop, Claude Code, and others) hybrid keyword + semantic search over them. Fully offline, zero configuration, read-only by design.
Add to your project's .mcp.json (or ~/.claude.json for all projects):
Add to claude_desktop_config.json (Settings β Developer β Edit Config):
Running from a source checkout instead: "command": "uv", "args": ["run", "--directory", "/path/to/docsonar", "docsonar"].
Then just talk to it: "Add my ~/Documents/notes folder and find everything about quarterly planning." The first index downloads the embedding model (~130 MB, one time); keyword search works immediately while that happens.
For HTTP instead of stdio: uvx docsonar --transport http --port 8365.
| Tool | Purpose |
|---|---|
add_folder(path, include_globs?, exclude_globs?) | Register a folder; indexing starts in the background |
remove_folder(path) | Unregister and purge its index data |
list_folders() | Registered folders with counts and last index time |
search(query, top_k?, folder?, file_type?, mode?) | Hybrid keyword+semantic search (RRF-fused); ranked passages with file path, heading/page location, and snippet |
read_file(path, start_line?, end_line?) | File text (extracted text for pdf/docx/html); refuses paths outside registered folders |
find_similar(path, top_k?) | Documents most similar in meaning to a given file |
reindex(folder?, force?) | Incremental refresh: new/changed files reindexed, deleted files purged |
index_status() | Index totals, embedding model state, background job progress, failed files |
Supported formats: txt, md, pdf (page-aware, cites p. 12), docx, html.
Every chunk stores its location (heading path like Setup > Windows, or PDF page range), so search results can cite report.pdf, p. 12.
mode lets the caller force either side.search returns enough per hit (path, location, score, snippet) to decide what to read next without another round trip; results carry stable chunk_ids; every degradation is reported in-band via note/embedding_note fields instead of failing. There's no "answer the question" tool on purpose β the calling model does the reasoning; docsonar does retrieval.Synthetic corpus of 200 markdown files (600 chunks); Intel Core Ultra 5 125U (laptop, CPU-only), Windows 11, Python 3.12. Reproduce with uv run python scripts/benchmark.py.
| Operation | Result |
|---|---|
| Index, keyword-only | 0.7 s (β280 files/s) |
| Index, with embeddings | 59 s (β3.4 files/s β embedding-bound) |
| Incremental reindex, nothing changed | 0.03 s |
| Search, keyword | 8.9 ms median |
| Search, semantic | 35 ms median |
| Search, hybrid | 54 ms median |
| Embedding model load (once per process) | ~21 s |
| Database size | 2.6 MB (1.1 MB keyword-only) |
Zero config needed. To customize, create config.toml in the platform config directory (Windows: %LOCALAPPDATA%\docsonar\, macOS: ~/Library/Application Support/docsonar/, Linux: ~/.config/docsonar/):
CLI flags: --transport stdio|http, --host, --port, --db-path, --config.
The index database lives in the platform data directory (Windows: %LOCALAPPDATA%\docsonar\, macOS: ~/Library/Application Support/docsonar/, Linux: ~/.local/share/docsonar/).
Requires uv (it installs the right Python automatically):
VS Code: press F5 β launch configs for the HTTP server and the test suite are in .vscode/launch.json.
With the HTTP server running, the endpoint is http://127.0.0.1:8365/mcp. Recent Postman versions can connect directly (New β MCP Request, transport HTTP) and show all 8 tools as forms. For raw HTTP, MCP is JSON-RPC over POST with two setup calls, then tool calls. Send every request with headers Content-Type: application/json and Accept: application/json, text/event-stream:
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/docsonar)<a href="https://allmcps.com/mcp/docsonar"><img src="https://allmcps.com/api/badge/docsonar?style=directory" alt="Docsonar on AllMCPs" /></a>