Skip to main content
Glama

Obsidian MCP Server

A Model Context Protocol (MCP) server for Obsidian vault operations. Works with any MCP-compatible client including Claude Desktop, Cursor, Windsurf, and VS Code.

Features

  • Full Vault Access: Read, write, search, and delete notes

  • Link Navigation: Get outgoing links and backlinks for any note

  • Tag Management: List all tags, find notes by tag

  • Flexible Search: Search by content, title, tags, or folder

  • Two Transports: Stdio (local) or Streamable HTTP (remote)

  • Modern MCP: Built with MCP SDK 1.6.1, Zod validation, tool annotations

Related MCP server: Obsidian MCP Server

Quick Start

# Install dependencies
npm install

# Build
npm run build

# Run (stdio mode)
OBSIDIAN_VAULT_PATH=/path/to/vault npm start

# Run (HTTP mode)
OBSIDIAN_VAULT_PATH=/path/to/vault npm run start:http

Configuration

Environment Variables

Variable

Required

Default

Description

OBSIDIAN_VAULT_PATH

Yes

-

Absolute path to your Obsidian vault

TRANSPORT

No

stdio

Transport mode: stdio or http

PORT

No

3000

HTTP server port

HOST

No

127.0.0.1

HTTP server host

DEBUG

No

false

Enable debug logging

MCP Client Configuration

Claude Desktop / Cursor / Windsurf (stdio)

{
  "mcpServers": {
    "obsidian": {
      "command": "node",
      "args": ["/path/to/obsidian-mcp-server/dist/index.js"],
      "env": {
        "OBSIDIAN_VAULT_PATH": "/path/to/your/vault"
      }
    }
  }
}

HTTP Mode

Start the server:

OBSIDIAN_VAULT_PATH=/path/to/vault TRANSPORT=http npm start

Connect via http://localhost:3000/mcp

Available Tools

Note Operations

Tool

Description

obsidian_list_notes

List notes with pagination and folder filtering

obsidian_read_note

Read a note's full content and metadata

obsidian_write_note

Create or update a note

obsidian_delete_note

Permanently delete a note

obsidian_search_notes

Search notes by content, tags, or folder

Vault Information

Tool

Description

obsidian_vault_stats

Get vault statistics (note count, size, etc.)

obsidian_list_tags

List all tags with usage counts

obsidian_get_tagged_notes

Get all notes with a specific tag

Tool

Description

obsidian_get_links

Get outgoing links from a note

obsidian_get_backlinks

Get backlinks to a note

Response Formats

All tools support a response_format parameter:

  • json (default): Structured JSON data

  • markdown: Human-readable markdown

Development

# Development mode (with auto-reload)
npm run dev

# Build
npm run build

# Test (builds and runs --help)
npm test

Project Structure

src/
  index.ts      # Entry point, transport handling
  server.ts     # MCP server with tool registrations
  vault.ts      # Vault operations (CRUD, search, links)
  schemas.ts    # Zod input validation schemas
  types.ts      # TypeScript type definitions

License

MIT

Available Tools

10 tools
obsidian_delete_noteDelete Obsidian NoteA
DestructiveIdempotent

Permanently delete a note from the vault.

WARNING: This action cannot be undone. The note file will be removed from the filesystem.

Inputs: path (required).

obsidian_get_tagged_notesGet Notes by TagA
Read-onlyIdempotent

Get all notes that have a specific tag.

The tag can be provided with or without the # prefix.

Returns: { "tag": string, "total": number, "notes": [{ "path": string, "name": string, "tags": string[] }] }

Inputs: tag (required), limit, response_format.

obsidian_list_notesList Obsidian NotesA
Read-onlyIdempotent

List notes in the Obsidian vault with pagination support.

Returns a list of note paths, names, tags, and modification dates. Use 'folder' to filter to a specific directory. Use 'offset' and 'limit' for pagination on large vaults.

Returns JSON by default with schema: { "total": number, "count": number, "offset": number, "notes": [{ "path": string, "name": string, "tags": string[], "modified": string }], "hasMore": boolean, "nextOffset"?: number }

Inputs: limit, folder, offset, response_format.

obsidian_list_tagsList All TagsA
Read-onlyIdempotent

List all tags used in the vault with their usage counts.

Tags are extracted from both YAML frontmatter and inline #tags. Results are sorted by frequency (most used first).

Returns: { "total": number, "tags": [{ "tag": string, "count": number }] }

Inputs: response_format.

obsidian_read_noteRead Obsidian NoteA
Read-onlyIdempotent

Read the full content of a specific note by path.

The path can be with or without .md extension. Set include_frontmatter=false to get only the markdown content.

Returns: { "path": string, "name": string, "content": string, "frontmatter"?: object, "tags": string[], "modified": string }

Inputs: path (required), include_frontmatter.

obsidian_search_notesSearch Obsidian NotesA
Read-onlyIdempotent

Search notes by content, title, tags, or folder.

  • 'query': Full-text search in content and titles

  • 'tags': Filter to notes with any of these tags

  • 'folder': Filter to notes in a specific folder

  • 'include_content': Include full content in results (default: false)

Returns ranked results with match information: { "total": number, "results": [{ "path": string, "name": string, "score": number, "matches": string[], "tags": string[], "excerpt"?: string }] }

Inputs: tags, limit, query, folder, +2 more.

obsidian_vault_statsGet Vault StatisticsA
Read-onlyIdempotent

Get statistics about the Obsidian vault.

Returns: { "totalNotes": number, "totalSize": number (bytes), "totalTags": number, "lastModified": string (ISO date) }

Inputs: response_format.

obsidian_write_noteWrite Obsidian NoteA
Idempotent

Create or update a note in the vault.

Provide markdown content and optionally YAML frontmatter. Directories are created automatically if they don't exist. Set overwrite=false to prevent overwriting existing notes.

Returns the created/updated note metadata.

Inputs: path (required), content (required), overwrite, frontmatter.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 10 tools

    Disambiguation5/5

    Each tool targets a distinct operation: CRUD, search, stats, links, backlinks, and tag management. Even similar tools like list_tags and get_tagged_notes serve clearly different purposes (listing all tags vs. retrieving notes with one tag).

    Naming Consistency5/5

    All tools follow a consistent pattern: obsidian_ + verb_noun in lowercase snake_case. The verbs (delete, list, read, write, search, get) are predictable and match the action.

    Tool Count5/5

    With 10 tools, the server is well-scoped for its purpose. Each tool covers a necessary aspect of Obsidian vault management without unnecessary bloat.

    Completeness5/5

    The tool surface provides full coverage for note CRUD, search, link graph, and tag operations. It supports creating, reading, updating (via write), deleting, listing, searching, and exploring connections. Minor missing operations like rename/move are not critical gaps.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Enables AI assistants to interact with Obsidian vaults for creating, reading, searching, and managing notes, daily notes, TODOs, session reports, and backlinks through both stdio and HTTP/SSE transports.
      10
      3,512 npm
      4
      MIT
    • F
      license
      A
      quality
      Not graded
      maintenance
      Integrates with the Obsidian Local REST API to enable reading, creating, editing, and searching notes within an Obsidian vault. It supports advanced operations like Dataview queries and partial file updates through both stdio and HTTP transport modes.
      8
      7,397 npm
      -
    • F
      license
      A
      quality
      D
      maintenance
      Enables interaction with multiple Obsidian vaults through natural language, supporting note operations, search, and vault management with both REST and filesystem backends.
      17
      -