ObsidianMCPServer
A Model Context Protocol (MCP) server that enables AI assistants to interact with your Obsidian vault
claude mcp add --transport stdio otaviocc-obsidianmcpserver ./ObsidianMCPServer \ --env OBSIDIAN_API_KEY="your-api-key-here" \ --env OBSIDIAN_BASE_URL="http://127.0.0.1:27123"
How to use
ObsidianMCPServer exposes a Model Context Protocol interface that lets your AI tools read, modify, and query notes within your Obsidian vault via the Local REST API. The server provides a suite of tools divided into Active Note, Vault Note, Directory & Search, Bulk Operations, and Periodic Notes. You can fetch server details, read or edit the currently open note, manipulate frontmatter, create or update arbitrary vault notes, perform vault-wide searches, apply batch changes, and manage time-based notes (daily, weekly, monthly, etc.). Integrations are designed to work with AI assistants like Claude or Cursor by presenting a stable API surface for note operations without exposing internal vault paths directly to the AI.
To use it, start the Obsidian Local REST API plugin in Obsidian, launch ObsidianMCPServer, and ensure the server can reach the Obsidian API endpoint at the configured base URL. In your AI tool configuration, point the MCP server to the executable and provide the necessary base URL and API key if required. The available tools (e.g., getActiveNote, updateActiveNote, getNote, createOrUpdateNote, search, bulkApplyTagsFromSearch, and the various daily/weekly/monthly note operations) are exposed as structured calls that your AI can invoke to read or modify content as part of a larger workflow.
How to install
Prerequisites:
- Obsidian installed with the Local REST API plugin enabled and an API key configured.
- A supported environment for running the MCP server binary (macOS/Linux/Windows with Swift-built binary or prebuilt executable).
Installation steps:
-
Build or obtain the ObsidianMCPServer executable
-
From source (Swift): git clone https://github.com/otaviocc/ObsidianMCPServer.git cd ObsidianMCPServer swift build -c release
The executable will be at: .build/release/ObsidianMCPServer
-
From prebuilt install (if available): follow the project’s release instructions and note the path to the executable.
-
-
Prepare the command configuration
- Decide where to run the server from and ensure it can access the Obsidian Local REST API at the base URL (default http://127.0.0.1:27123).
- If needed, adjust the OBSIDIAN_BASE_URL and OBSIDIAN_API_KEY environment variables in your run configuration.
-
Run the server
- Basic example (adjust path as needed): ./ObsidianMCPServer
-
Verify accessibility
- Check the server is responding and that the Obsidian Local REST API is reachable at the configured base URL.
Note: If you are packaging this for a deployment pipeline, ensure the executable permission is set (chmod +x ObsidianMCPServer on Unix-like systems) and provide proper environment variables for the Obsidian API access.
Additional notes
Tips and common considerations:
- Environment variables:
- OBSIDIAN_BASE_URL: Base URL for Obsidian Local REST API (default http://127.0.0.1:27123).
- OBSIDIAN_API_KEY: API key from the Local REST API plugin settings.
- Ensure the Obsidian vault is accessible by the MCP server process and that the Local REST API is up before starting the MCP server.
- When referencing notes, use predictable filenames and be aware of vault structure to avoid conflicts when using bulk operations.
- If you run into authentication or access errors, double-check the API key and base URL configuration in the environment.
- For persistent deployments, consider wrapping the server in a process manager (systemd, PM2, etc.) and expose the appropriate health checks.
Related MCP Servers
mcp-telegram
MCP Server for Telegram
agentql
Model Context Protocol server that integrates AgentQL's data extraction capabilities.
unity-api
Instant, accurate Unity API lookups instead of expensive source file reads, saving your agent tokens, context, and hallucinations
mcp-claude-spotify
An integration that allows Claude Desktop to interact with Spotify using the Model Context Protocol (MCP).
mcp-rss-aggregator
Model Context Protocol Server for aggregating RSS feeds in Claude Desktop
1c
Curated list of MCP servers for 1C:Enterprise ecosystem | Каталог MCP-серверов для экосистемы 1С:Предприятие