Skip to main content
Glama
mcp-obsidian

mcp-obsidian

by chzkyy

mcp-obsidian

MCP server that connects Claude Desktop to Obsidian via the Local REST API plugin.

Overview

mcp-obsidian is a Node.js/TypeScript MCP server that exposes your Obsidian vault to Claude Desktop over stdio.
It talks to the Obsidian Local REST API plugin and provides tools for searching, reading, writing, and managing notes, plus running Obsidian commands.

Related MCP server: obsidian-mcp

Features (Available MCP Tools)

Based on src/index.ts, this server currently exposes:

  1. search_notes - search notes using Obsidian query syntax

  2. get_note - read full markdown content by vault-relative path

  3. create_note - create a new note (overwrite optional)

  4. update_note - replace full content of an existing note

  5. append_note - append or prepend content to a note

  6. delete_note - delete a note

  7. list_directory - list files/folders under a vault directory

  8. open_note - open a note in the Obsidian app

  9. list_commands - list available Obsidian command IDs

  10. execute_command - execute an Obsidian command by ID

  11. get_active_note - get content of the active note in Obsidian

Requirements

  • Node.js 18+ (Node 20+ recommended)

  • Obsidian desktop app

  • Obsidian plugin: Local REST API installed and enabled

  • API key from the Local REST API plugin settings

Environment Variables

Required:

  • OBSIDIAN_BASE_URL (example: https://127.0.0.1:27124)

  • OBSIDIAN_API_KEY (token/license key from plugin settings)

Optional (only if you use self-signed TLS cert from local plugin):

  • NODE_TLS_REJECT_UNAUTHORIZED=0

Security note: disable TLS verification only for local trusted use.

Installation & Build

npm install
npm run build

Build output will be generated in dist/.

Claude Desktop Configuration

Use claude_desktop_config.example.json as reference.

Example:

{
  "mcpServers": {
    "obsidian": {
      "command": "node",
      "args": ["/absolute/path/to/mcp_obsidian/dist/index.js"],
      "env": {
        "OBSIDIAN_BASE_URL": "https://127.0.0.1:27124",
        "OBSIDIAN_API_KEY": "YOUR_LOCAL_REST_API_KEY_HERE",
        "NODE_TLS_REJECT_UNAUTHORIZED": "0"
      }
    }
  }
}

Adjust args to the absolute path on your machine.

Usage Examples

After Claude Desktop loads this MCP server, you can call tools like:

  • Search notes:

    • tool: search_notes

    • args: {"query":"tag:#project","context_length":120}

  • Read note:

    • tool: get_note

    • args: {"path":"Projects/Plan.md"}

  • Create note:

    • tool: create_note

    • args: {"path":"Journal/2026-08-17.md","content":"# Daily Log\\n- ...","overwrite":false}

  • Append note:

    • tool: append_note

    • args: {"path":"Inbox.md","content":"\\n- New item","mode":"append"}

  • Run command:

    • tool: execute_command

    • args: {"command_id":"app:go-home"}

Project Structure

.
├── src/
│   ├── index.ts         # MCP server entrypoint, tool schema + handlers
│   └── obsidianApi.ts   # Obsidian Local REST API client wrapper
├── claude_desktop_config.example.json
├── package.json
└── tsconfig.json

Obsidian Local REST API Plugin Note

This project depends on the Local REST API plugin endpoints (/vault, /search/simple, /commands, /active, /open).
If the plugin is not installed/enabled or API key/base URL is wrong, MCP tools will fail.

Available Tools

11 tools
append_noteA

Append (or prepend) markdown content to an existing note without replacing it.

Inputs: path (required), content (required), mode.

create_noteA

Create a new note in the vault with markdown content. Refuses to overwrite an existing note unless overwrite=true.

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

delete_noteA

Permanently delete a note from the vault.

Inputs: path (required).

execute_commandA

Execute an Obsidian command by its id (use list_commands first).

Inputs: command_id (required).

get_active_noteA

Get the markdown content of the currently active note in Obsidian.

Inputs: no named parameters.

get_noteA

Read the full markdown content of a note by its vault-relative path.

Inputs: path (required).

list_commandsA

List all available Obsidian commands that can be executed.

Inputs: no named parameters.

list_directoryA

List files and folders under a vault directory. Use directory='' or '/' for the vault root.

Inputs: directory.

open_noteA

Open a note in the Obsidian app window by its vault path.

Inputs: path (required).

search_notesB

Search notes in the Obsidian vault using Obsidian's search query syntax. Returns matching paths, scores, and snippets.

Inputs: query (required), context_length.

update_noteA

Replace the entire content of an existing note with new markdown content.

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

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 11 tools

    Disambiguation5/5

    Each tool targets a distinct operation: search, read by path, read active note, create, replace, append, delete, list directory, open in UI, and command management. Even similar tools like get_note and get_active_note are clearly separated by how the note is selected.

    Naming Consistency5/5

    All tool names consistently use lowercase snake_case with a verb_noun pattern (search_notes, get_note, create_note, list_commands, execute_command). There are no style deviations or ambiguous generic names.

    Tool Count5/5

    11 tools is well-scoped for a note management server: it covers search, CRUD, directory listing, UI actions, and Obsidian command execution without bloat or redundancy.

    Completeness5/5

    The surface provides full lifecycle coverage for notes—create, read, update, append, delete—plus search, directory browsing, opening notes, and executing commands. No critical dead ends for typical Obsidian automation workflows.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Bidirectional MCP server that connects Claude with an Obsidian vault, enabling note management, full-text search, graph traversal, and daily notes operations.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server for interacting with Obsidian via the Local REST API, enabling file operations, search, and content editing in your vault.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server to interact with Obsidian via the Local REST API community plugin, enabling file listing, search, content manipulation, and note management.
      MIT