obsidian-mcp-rest
Provides tools for interacting with an Obsidian vault through the Obsidian REST API, including file CRUD, active-file operations, search (Dataview DQL, full-text, and optional semantic search), template execution, MCP prompt discovery, and web content conversion to Markdown.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
obsidian-mcp-rest
A lightweight MCP (Model Context Protocol) server for Obsidian, built as a thin wrapper over the Obsidian REST API.
Also available as an Obsidian plugin with settings UI, auto-detection of obsidian-api, and one-click MCP server installation.
Zero npm dependencies. Node.js built-ins only.
Features
18 MCP tools — full vault CRUD, search, templates, active file operations
MCP prompts — auto-discovery of prompt templates from vault
Obsidian plugin — settings tab with auto-detect, install, and copyable config
Zero dependencies — uses only Node.js built-in modules
UTF-8 correct — all markdown operations preserve Unicode properly
PATCH v3 — heading/block/frontmatter targeting +
search-replacefor precise text substitutionWeb fetch — built-in HTML to Markdown conversion
Related MCP server: Obsidian MCP Server
Requirements
Node.js >= 20
obsidian-api plugin (or obsidian-local-rest-api)
API key configured in the plugin settings
Optionally: Smart Connections plugin (for
search_vault_smart)Optionally: Templater plugin (for
execute_templateand prompts)
Installation
As MCP server
npx -y @swarogan/obsidian-mcp-restAs Obsidian plugin
Download
main.js,manifest.json, andstyles.cssfrom the latest releaseCreate
<vault>/.obsidian/plugins/obsidian-mcp-rest/and place the files thereEnable the plugin in Obsidian settings
The plugin auto-detects obsidian-api settings and provides a copyable MCP config
Configuration
Set environment variables:
Variable | Required | Default | Description |
| Yes | — | Bearer token from plugin settings |
| No |
| Obsidian REST API URL |
| No |
| Request timeout in ms |
MCP Client Configuration
Claude Code
claude mcp add obsidian -e OBSIDIAN_API_KEY="your-api-key" -- npx -y @swarogan/obsidian-mcp-restClaude Desktop / other MCP clients
{
"mcpServers": {
"obsidian": {
"command": "npx",
"args": ["-y", "@swarogan/obsidian-mcp-rest"],
"env": {
"OBSIDIAN_API_KEY": "your-api-key",
"OBSIDIAN_REST_URL": "https://127.0.0.1:27124"
}
}
}
}Available MCP Tools
Server
get_server_info— API status (no auth required)
Active File
get_active_file— read current file (markdown or JSON)update_active_file— replace entire contentappend_to_active_file— append contentpatch_active_file— patch heading/block/frontmatter or search-replace textdelete_active_file— delete current fileshow_file_in_obsidian— open file in Obsidian UI
Vault Files
list_vault_files— list directory contentsget_vault_file— read file by pathcreate_vault_file— create or overwrite fileappend_to_vault_file— append to filepatch_vault_file— patch heading/block/frontmatter or search-replace textdelete_vault_file— delete file
Search
search_vault— Dataview DQL or JsonLogic queriessearch_vault_simple— full-text search with contextsearch_vault_smart— semantic search (requires Smart Connections)
Other
execute_template— run Templater templates with argumentsfetch— download web content, convert HTML to markdown
MCP Prompts
The server supports MCP prompts capability:
Auto-discovers
.mdfiles inPrompts/directory withobsidian-mcp-rest-prompttagParses
tp.mcpTools.prompt(...)calls for argument definitionsExecutes templates via Templater plugin
Strips frontmatter from output
Tests
npm test28 tests covering tools, prompts, client, UTF-8, PATCH operations, and stdio transport.
Network Usage
This MCP server communicates only with the local Obsidian REST API (default 127.0.0.1:27124). It does not connect to any external services.
The fetch tool makes outbound HTTP requests only when explicitly invoked by the user.
Support
If this project is useful to you and you'd like to support further development, you can do so on Ko-fi.
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.
Connect AI assistants to your GitHub-hosted Obsidian vault to seamlessly access, search, and analy…
Search your Obsidian vault to quickly find notes by title or keyword, summarize related content, a…
Persistent memory and knowledge management for AI agents with semantic search and 50+ tools.
Related MCP Servers
- AlicenseAqualityDmaintenanceEmpowers AI agents to deeply understand and interact with Obsidian vaults through the Local REST API, enabling advanced features like vault structure discovery, graph analysis, command execution, and batch file operations.1618MIT
- FlicenseNot gradedqualityNot gradedmaintenanceEnables AI assistants to read, write, search, and navigate Obsidian vault notes with support for CRUD operations, full-text search, graph navigation, daily notes, and frontmatter management.4,114 npm-
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to manage Obsidian vaults through full CRUD operations, wikilink management, and section-level manipulation. It supports frontmatter editing, tag-based searching, and automated link updates to maintain vault integrity.MIT
- FlicenseCqualityDmaintenanceProvides LLM agents with comprehensive access to Obsidian vaults via the official Obsidian CLI bridge. It enables users to read, search, and modify notes, tasks, properties, and plugins while the Obsidian desktop app is running.5416-