Skip to main content

obsidian-mcp (Python)

A Python MCP (Model Context Protocol) server giving an LLM client (e.g. Claude Desktop) read/write access to local Obsidian vaults, via direct filesystem access — no Obsidian Local REST API plugin, no HTTP, no auth token required.

This is a Python port of obsidian-mcp (TypeScript), functionally equivalent with a few deliberate fixes and simplifications — see Plans/review-the-typescript-obsidian-mcp-parsed-shamir.md and ISA.md for the full rationale.

Warning: This server has read/write access to your vault. Back up your notes (e.g. via git) before use.

Requirements

  • Python 3.11+
  • uv
  • An Obsidian vault (a directory that has been opened by Obsidian at least once, i.e. contains a .obsidian/app.json)
  • macOS or Linux (Windows is not supported — see ISA "Out of Scope")

Install & run

The PyPI distribution is named py-obsidian-mcp (the obsidian-mcp name was already taken by an unrelated project) — the installed command is still obsidian-mcp.

uvx --from py-obsidian-mcp obsidian-mcp /path/to/your/vault [/path/to/another/vault ...]
# or: pip install py-obsidian-mcp && obsidian-mcp /path/to/your/vault

From source (development)

uv sync
uv run obsidian-mcp /path/to/your/vault [/path/to/another/vault ...]

Vault names are auto-derived from each directory's basename (lowercased, non-alphanumeric characters become hyphens, duplicates get a numeric suffix). Up to 10 vaults; vault paths must not be nested inside one another.

Claude Desktop configuration

Edit claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "obsidian": {
      "command": "uvx",
      "args": ["--from", "py-obsidian-mcp", "obsidian-mcp", "/path/to/your/vault"]
    }
  }
}

Or, running from a local clone instead of the published package:

{
  "mcpServers": {
    "obsidian": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/py-obsidian-mcp", "obsidian-mcp", "/path/to/your/vault"]
    }
  }
}

Tools

read-note, create-note, edit-note (append/prepend/replace/delete), delete-note (soft-delete to .trash/ by default), move-note, create-directory, search-vault (content/filename/tag search, with an optional max_results), add-tags, remove-tags, rename-tag (vault-wide, hierarchy-preserving), list-available-vaults.

Also exposes an obsidian-vault:// resource scheme (vault listing/info) and a list-vaults prompt.

Development

uv sync --all-extras
uv run pytest -q
uv run ruff check src tests

Security notes

  • Every tool validates that target paths stay within the vault (src/obsidian_mcp/utils/path_safety.py), including symlink-aware containment checks.
  • The TypeScript original had a confirmed bug where this containment check was effectively a no-op (an async validation function was called without await). This port's path-safety functions are all synchronous, structurally preventing that class of bug.

Metadata

Release files for py-obsidian-mcp 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py-obsidian-mcp 0.1.1
File Size Uploaded
py_obsidian_mcp-0.1.1.tar.gz 27.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py-obsidian-mcp 0.1.1
File Interpreter ABI Platform
py_obsidian_mcp-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 71.7 kB

Release files / py_obsidian_mcp-0.1.1.tar.gz

Download URL py_obsidian_mcp-0.1.1.tar.gz
Size 27.2 kB
Tags Source
SHA-256 checksum
How to use checksums
f40ec8642fba43e6c75f7c87a3835068f06747c2d9d4f7ee9d8d31bc45ed4db0
BLAKE2b-256 checksum
How to use checksums
651f4ae9ad1d7281592a88411779f14315df30c49ff9a6aa0685dac250331e10
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 23, 2026.

Transparency log

Release files / py_obsidian_mcp-0.1.1-py3-none-any.whl

Download URL py_obsidian_mcp-0.1.1-py3-none-any.whl
Size 44.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
88bdae5b22bbdbcea5c90a897ddd5c4766d7e8f0b52dbbf920f28bf7882ba3f0
BLAKE2b-256 checksum
How to use checksums
3592654288c7e42842b63ce7c921eb4e432c6f2ce5b8e28a0f006f46b7c44bb3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 23, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page