Get the FREE Ultimate OpenClaw Setup Guide →

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.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
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)

  1. Ensure Docker is running.
  2. 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)

  1. Install Go 1.20+ and required build tools.
  2. Clone the repository and navigate to the project root: git clone https://github.com/Atomzwieback/obsidian-search-mcp.git cd obsidian-search-mcp
  3. Build the binary (CGO and Tantivy C libraries must be available): CGO_ENABLED=1 go build -o obsidian-search-mcp cmd/server/main.go
  4. 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

Sponsor this space

Reach thousands of developers