The Lost Engineer`s Guide
Published on
//

Obsidian MCP: Connect your markdown

Authors
obsidian-mcp

Obsidian MCP: Connect your markdown

If you keep notes in markdown, whether that is Obsidian, a flat folder, or some other PKM tool, you have probably run into the same friction with LLMs: the model has no idea your notes exist. You end up copy-pasting snippets into chat windows, describing your folder layout in plain English, or just doing things manually because explaining where stuff lives takes longer than the task itself.

obsidian-mcp is an MCP server that gives LLMs direct read and write access to a folder of markdown files. Hook it up to Claude and the model can search notes, query frontmatter, trace backlinks, create files, batch-update metadata, and manage tags across thousands of notes. The vault becomes something the LLM can actually work with instead of something you relay by hand.

What is MCP

MCP (Model Context Protocol) is a standard that lets LLMs call external tools through a shared interface. If you have used function calling in any LLM API, same idea, just standardised so one server works with any compatible client. Claude Desktop and claude.ai support it natively.

Setting it up

Add the server to your Claude Desktop config. On macOS that is ~/Library/Application Support/Claude/claude_desktop_config.json, on Windows %APPDATA%\Claude\claude_desktop_config.json:

{
  "mcpServers": {
    "markdown-vault": {
      "command": "npx",
      "args": ["-y", "obsidian-mcp", "/path/to/your/vault"]
    }
  }
}

Restart Claude Desktop. The hammer icon shows up and you are connected. That is the whole setup.

Multiple vaults work too:

{
  "mcpServers": {
    "markdown-vault": {
      "command": "npx",
      "args": [
        "-y", "obsidian-mcp",
        "/path/to/vault1",
        "/path/to/vault2"
      ]
    }
  }
}

Up to 10 folders. Docker is also an option if containers are more your thing.

What it actually does

The server exposes 16 tools. Here is what they cover.

Search and query

Full-text search, regex, tag filtering. You can query by frontmatter fields, things like "find every note where status: draft" or "everything tagged project-x with a date after January." The backlink tool traces which notes link to or mention a given file. Vault stats show tag frequency, folder distribution, and frontmatter key usage across the whole collection.

On a vault with thousands of files, finding a specific subset matching two or three criteria usually means either Obsidian's built-in search (which tops out at text matching) or writing a throwaway script. With the MCP server connected, you just ask.

Write and organise

Create notes with frontmatter pre-populated. Edit existing files. Move things between folders. Delete what you do not need. Build directory structures. Write operations use file locking so the server will not corrupt something you have open in your editor.

Mid-conversation about a project, you can say "create a note for this in my projects folder with status planning" and it lands in the vault with proper frontmatter, ready for Obsidian queries. No tab-switching, no manual file creation.

Metadata at scale

Batch-update frontmatter across every note matching a query. Add or remove tags from individual files. Rename a tag across the entire vault in one call. All with dry-run so you can preview before committing.

Over months, vaults accumulate tag drift: #wip, #WIP, #work-in-progress, #in_progress. Cleaning that up by hand is the kind of task that keeps getting deferred. One rename-tag call fixes every file.

Usage examples

Pull every note referencing a topic before a meeting and have the model summarise what has been written across all of them. The model reads the actual files rather than working from memory.

Finish a piece of work, then batch-update the status field on the relevant notes from in-progress to complete and add a completed-date with today's date. Done in seconds.

Use the backlink tool to find orphaned notes that nothing links to. Those are candidates for cleanup or re-linking. Pull vault stats periodically to check which tags are multiplying and whether the folder structure still makes sense.

The pattern is always the same: instead of switching into Obsidian, running a search, reading through results, then switching back to the conversation, the model handles it inline.

Back up your vault

The server has full read and write access to your files. Use git or whatever backup you trust. If a batch operation does something unexpected, you want a way to undo it.

It does not depend on Obsidian

Despite the name, the server works with any folder of .md files. Different PKM tool, plain markdown in a directory, whatever. If it is a markdown file with optional YAML frontmatter, it is supported.