MCP Directory

How to add mcp-obsidian (Obsidian Local REST API) to Windsurf

Read, search, and edit your Obsidian vault through the Local REST API community plugin. Paste the config into ~/.codeium/windsurf/mcp_config.json and restart Windsurf.

Last updated June 15, 2026 · 3.6k · stdio · apikey

Windsurf config for mcp-obsidian (Obsidian Local REST API)

uvx mcp-obsidian
{
  "mcpServers": {
    "mcp-obsidian-obsidian-local-rest-api": {
      "command": "uvx",
      "args": [
        "mcp-obsidian"
      ],
      "env": {
        "OBSIDIAN_HOST": "127.0.0.1",
        "OBSIDIAN_PORT": "27124",
        "OBSIDIAN_API_KEY": "<your-obsidian-rest-api-key>"
      }
    }
  }
}

Requires `uv` (the Python package runner). Install it from https://docs.astral.sh/uv/ if `uvx` is not found.

Setup steps

  1. 1Open Windsurf → Cascade → the hammer/MCP icon → Configure (or edit ~/.codeium/windsurf/mcp_config.json).
  2. 2Paste the mcp-obsidian (Obsidian Local REST API) config below.
  3. 3Fill in placeholder secrets, then save.
  4. 4Click Refresh in the MCP panel.
  5. 5mcp-obsidian (Obsidian Local REST API)'s tools become available to Cascade.

Before you start

  • Obsidian installed with the 'Local REST API' community plugin installed and enabled
  • An API key generated in the Local REST API plugin's settings, set as OBSIDIAN_API_KEY
  • Python with uv/uvx available (the server is run via `uvx mcp-obsidian`)
  • The plugin's host/port reachable — defaults are OBSIDIAN_HOST 127.0.0.1 and OBSIDIAN_PORT 27124
  • Obsidian must be running for the server to reach the vault

What mcp-obsidian (Obsidian Local REST API) can do in Windsurf

list_files_in_vault

List all files and directories at the root of the vault.

list_files_in_dir

List files and directories inside a specific directory.

get_file_contents

Return the full contents of a single note/file.

search

Search across the vault for documents matching a text query.

patch_content

Insert content relative to a heading, block reference, or frontmatter field in a file.

append_content

Append content to a new or existing file.

delete_file

Delete a file or directory from the vault.

Security

Requires the Obsidian Local REST API plugin and its API key, which grants full read/write access to your local vault — keep OBSIDIAN_API_KEY in env vars. The server only talks to a local endpoint, so do not expose the REST API plugin to the network.

mcp-obsidian (Obsidian Local REST API) + Windsurf FAQ

Where is the Windsurf config file?

Windsurf reads MCP servers from ~/.codeium/windsurf/mcp_config.json. Paste the mcp-obsidian (Obsidian Local REST API) config there under the "mcpServers" key and restart the client.

Is mcp-obsidian (Obsidian Local REST API) safe to use with Windsurf?

Requires the Obsidian Local REST API plugin and its API key, which grants full read/write access to your local vault — keep OBSIDIAN_API_KEY in env vars. The server only talks to a local endpoint, so do not expose the REST API plugin to the network.

Why isn't the server connecting to my vault?

Make sure Obsidian is open and the Local REST API plugin is enabled, and that OBSIDIAN_HOST/OBSIDIAN_PORT match the plugin (defaults 127.0.0.1 and 27124). The plugin uses HTTPS with a self-signed cert by default.

Where do I get the API key?

It's generated in the Local REST API plugin's settings inside Obsidian. Copy it into the OBSIDIAN_API_KEY environment variable.

Do I need Node, or is this Python?

It's a Python server, run with uvx (uv). You need uv/uvx available; no Node.js is required.

View repo Full mcp-obsidian (Obsidian Local REST API) page