Obsidian MCP Server

Chat with your second brain — search, read and write vault notes through the Local REST API.

Local serverstdioPythonMIT 2.2k

What is the Obsidian MCP server?

An Obsidian vault is years of thinking in markdown — and precisely because it's local plain files, no cloud AI can see it. The Obsidian MCP server bridges that gap on your terms: it talks to the community Local REST API plugin running inside your Obsidian, so your assistant can search, read, create and modify notes while everything stays on your machine.

The retrieval experience is the revelation. Vault search finds strings; an assistant with vault access finds ideas — "what have I written about spaced repetition, and did my opinion change?" gets synthesized from the four notes where you touched the topic, including the two you'd forgotten. Connections you didn't draw yourself surface for free, which is rather the promise of the tools-for-thought genre finally cashed out.

Writing workflows follow naturally: daily notes appended with captured thoughts, meeting transcripts distilled into permanent notes in your own format, messy fleeting notes reorganised, periodic reviews drafted from the week's activity. Since the server works through Obsidian itself, edits respect your vault exactly as if typed — no sync conflicts, no external mutation of files behind Obsidian's back.

Setup: install the Local REST API plugin, copy its API key, add the server via uvx. Two honest caveats. Obsidian must be running for the bridge to work — the REST API lives inside the app. And you're handing an assistant read/write over possibly your most personal corpus; the local-only architecture is exactly why this is tolerable, but keep vault backups regardless (you have git or sync on it anyway — right?).

Living with the bridge

  • The plugin serves HTTPS on port 27124 with a self-signed certificate; the plaintext listener on 27123 is off by default and is the usual handshake fix.
  • Complex search speaks the plugin's JsonLogic query format, which is what makes path- and frontmatter-shaped questions answerable at all.
  • Heading- and block-relative patching is the safest write mode: it inserts at a named anchor and leaves the rest of the note byte-identical.
  • Weekly and monthly periodic notes need the Periodic Notes plugin alongside core Daily Notes, or those fetches simply come back empty.

What you can do with it

Idea retrieval

Questions answered across every note that touches a topic — including the ones you forgot.

Daily-note capture

Thoughts appended to today's note without leaving the conversation.

Vault gardening

Fleeting notes distilled, structures reorganised, weekly reviews drafted.

Available tools

ToolWhat it does
obsidian_simple_searchText search across the vault
obsidian_complex_searchStructured queries (e.g. by path pattern)
obsidian_get_file_contentsRead a note
obsidian_append_contentAppend to a note (daily-note friendly)
obsidian_patch_contentInsert content relative to headings or blocks
obsidian_list_files_in_vaultBrowse the vault structure
obsidian_get_periodic_noteFetch today's daily (or other periodic) note

How to install the Obsidian MCP server

{
  "mcpServers": {
    "obsidian": {
      "command": "uvx",
      "args": ["mcp-obsidian"],
      "env": {
        "OBSIDIAN_API_KEY": "key-from-local-rest-api-plugin",
        "OBSIDIAN_HOST": "127.0.0.1"
      }
    }
  }
}

First install the 'Local REST API' community plugin in Obsidian and copy its API key.

Configuration

Obsidian running with the Local REST API community plugin enabled. Python with uv for the server.

VariableDescriptionRequired
OBSIDIAN_API_KEYAPI key shown by the Local REST API plugin settingsYes
OBSIDIAN_HOSTHost where Obsidian's REST API listense.g. 127.0.0.1Optional

Example prompts to try

  • Search my vault for notes about pricing strategy and synthesise my current position.
  • Append to today's daily note: idea for the newsletter — comparison of MCP servers.
  • Read my book notes on Thinking Fast and Slow and connect them to my decision-journal notes.

Frequently asked questions

The server and Obsidian's REST API both run locally; the assistant reads notes through your MCP client like any other context. No third-party service sits in the middle — which is the reason this setup is popular with people who chose Obsidian for privacy.