obsidian-search
🔍 Search your Obsidian vault directly from Claude. Fast full-text search powered by Tantivy-Go, giving AI instant access to your entire knowledge base.
claude mcp add --transport stdio atomzwieback-obsidian-search-mcp docker run -i --rm -e OBSIDIAN_VAULT_PATH=/vault -v /path/to/your/obsidian/vault:/vault:ro -v obsidian-mcp-index:/data atomzwieback/obsidian-search-mcp:latest \ --env MCP_INDEX_PATH="Path to index storage (optional; defaults to /data)" \ --env OBSIDIAN_VAULT_PATH="Path to your Obsidian vault (e.g., /vault)"
How to use
This MCP server provides fast, full-text search over your Obsidian vault. It uses Tantivy under the hood to index and search markdown notes, offering real-time updates and incremental indexing so only changed files are processed. Through the MCP interface, you can issue tools like search_vault to query your vault, reindex_vault to force a complete rebuild of the index, and check index_status to monitor indexing progress and health. This makes it easy to integrate Obsidian search into AI assistants or other MCP-enabled clients that need rapid access to your notes.
To use it, configure the server in your MCP client with the provided docker setup (or native binary if you prefer). Once the service is running, you can invoke search_vault with a query to retrieve matching notes, and you can run reindex_vault to refresh the index after large vault changes. The index_status tool helps you verify that indexing is current and to understand performance metrics like document count and indexing speed.
How to install
Prerequisites:
- Docker installed (or Go tooling for building from source)
- Access to your Obsidian vault
Option A: Docker (Recommended)
- Ensure Docker is running.
- Run the MCP configuration provided in this README through your MCP client, which will pull and start the container automatically. No extra setup required beyond configuring OBSIDIAN_VAULT_PATH to the location of your vault.
Option B: Build from Source (If you prefer running a native binary)
- Install Go 1.20+ and required build tools.
- Clone the repository and navigate to the project root: git clone https://github.com/Atomzwieback/obsidian-search-mcp.git cd obsidian-search-mcp
- Build the binary (CGO and Tantivy C libraries must be available): CGO_ENABLED=1 go build -o obsidian-search-mcp cmd/server/main.go
- Run the binary providing the vault path and index path as environment variables: OBSIDIAN_VAULT_PATH=/path/to/vault MCP_INDEX_PATH=/path/to/index ./obsidian-search-mcp
Additional notes
Environment variables:
- OBSIDIAN_VAULT_PATH (required): Path to your Obsidian vault directory
- MCP_INDEX_PATH (optional): Path to store the search index (defaults to a standard location if not provided)
Tips:
- For Docker usage, map your vault read-only to /vault to protect original files.
- If you add new notes or make significant edits, run reindex_vault to ensure the index stays in sync.
- Monitor index_status to understand indexing progress and performance characteristics.
Related MCP Servers
mcp -code-execution-mode
An MCP server that executes Python code in isolated rootless containers with optional MCP server proxying. Implementation of Anthropic's and Cloudflare's ideas for reducing MCP tool definitions context bloat.
sandbox
A Model Context Protocol (MCP) server that enables LLMs to run ANY code safely in isolated Docker containers.
docmole
Dig through any documentation with AI - MCP server for Claude, Cursor, and other AI assistants
obsidian
MCP server for Obsidian vault management - enables Claude and other AI assistants to read, write, search, and organize your notes
chromadb-remote
Remote MCP server for ChromaDB
nmap
MCP server for AI-powered network scanning with Nmap. Port scanning, service detection, OS fingerprinting, and vulnerability scanning for AI agents. By Vorota AI.