obsidian-wiki
Enables building and maintaining structured, persistent wikis in an Obsidian vault, with schema-validated page creation/update, search, link/backlink checks, health audits, project overviews, and git commits.
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-wiki-mcp
An MCP server for building structured, persistent wikis in Obsidian. The LLM writes and maintains the wiki; you curate in Obsidian.
Two agents with different roles: a librarian that organizes knowledge pages, and a researcher that thinks through problems and tracks progress in threads.
Quick start
# Install with uv
uv pip install -e .
# Initialize a vault
obsidian-wiki-init /path/to/my-wiki
# Open in Obsidian, then run Claude Code in the vault
cd /path/to/my-wiki
claudeThe init command creates everything: folder structure, page type schemas, style guide, landing page, CLAUDE.md, and slash commands. It also initializes git.
Related MCP server: paperloom
What you get
Vault structure
my-wiki/
├── CLAUDE.md # Agent identity (loaded every session)
├── Landing.md # Dataview dashboard (projects, activity, knowledge)
├── .claude/commands/
│ ├── wiki.md # /wiki — librarian operations
│ ├── wiki-audit.md # /wiki-audit — health checks
│ ├── wiki-ingest.md # /wiki-ingest — add papers/resources
│ ├── wiki-update-project.md # /wiki-update-project — sync with repos
│ └── research.md # /research — project-scoped research agent
├── _schemas/ # Page type definitions (YAML)
├── _wiki/style-guide.md # Writing conventions
├── references.bib # BibTeX citations
├── to_ingest/ # Drop files here for ingestion
├── knowledge/
│ ├── concepts/
│ ├── tools/
│ ├── people/
│ └── resources/attachments/
└── work/
├── daily/ # Auto-generated daily logs
└── projects/
└── {project-name}/
├── {project-name}.md # Project narrative
├── threads/ # Research threads
│ ├── index.md # Active/resolved thread list
│ └── {thread-slug}/
│ ├── {thread-slug}.md # Landing page
│ └── YYYY-MM-DD.md # Session notes
├── todos.md
├── experiments/
├── deliverables/
├── decisions/
├── tasks/
├── notes/
└── attachments/ # Raw files (gitignored)Agents
Librarian (/wiki) — organizes knowledge. Creates pages, validates schemas, maintains links, runs health checks. Quiet, careful, doesn't embellish.
Researcher (/research) — thinks about problems. Picks up threads, reasons step by step, accumulates notes in session files. Proposes wiki pages but delegates creation to the librarian. Presents new questions via AskUserQuestion so you choose what to pursue.
Page types
Knowledge layer (cross-project, long-lived): Concept, Tool, Person, Resource
Work layer (scoped to a project): Project, Deliverable, Experiment, Decision, Task, Note
Each type has a YAML schema defining required fields, enums, and defaults. Schema validation catches errors before pages are written.
MCP tool
A single wiki tool with 12 actions:
Action | Purpose |
| Create a page — validates schema, blocks duplicates |
| Page content + metadata + backlinks |
| Patch metadata and/or body |
| Full-text and metadata-filtered search (capped at 100) |
| Check pages against schemas |
| Orphans, stubs, broken links, duplicates |
| Project overview with children and artifacts |
| Backlinks and outlinks |
| Get/set generation sources |
| Git commit (all or specific files) + auto-append to daily log |
| Read/update the style guide |
| Move/rename files to attachments with BibTeX-key naming |
Slash commands
Command | Purpose |
| Librarian — create, update, organize wiki pages |
| Health check — broken links, orphans, stray files, stale todos |
| Add a paper or resource (supports |
| Diff a project's vault + repos since last update |
| Research agent — work threads, explore concepts, synthesize |
| Write brief narrative diary entries from git history and thread notes |
Link resolution
Wikilinks use [[slug|Display Name]] format. The health checker resolves links through three indices (slug, title, alias) and skips wikilinks inside code blocks.
For threads (where folder and file share a name): [[thread-slug/thread-slug|Thread Name]].
Configuration
Add the MCP server config to .mcp.json (or .claude/mcp.json):
{
"mcpServers": {
"obsidian-wiki": {
"command": "obsidian-wiki-mcp",
"env": {
"VAULT_PATH": "/path/to/my-wiki"
}
}
}
}If the binary isn't on PATH, use the full venv path:
{
"mcpServers": {
"obsidian-wiki": {
"command": "/path/to/obsidian-wiki-mcp/.venv/bin/obsidian-wiki-mcp",
"env": {
"VAULT_PATH": "/path/to/my-wiki"
}
}
}
}External repo access
Projects can link to external repos via repos metadata. Add repo paths to .claude/settings.local.json → permissions.additionalDirectories so agents can read them. The agent will ask before accessing any external directory.
Architecture
┌──────────────┐ MCP ┌──────────────────────┐
│ Claude Code │◄────────────►│ wiki MCP server │
└──────────────┘ │ (stateless, parses │
│ vault files on │
┌──────────┐ │ each request) │
│ Obsidian │ └──────────┬────────────┘
└────┬─────┘ │
│ shared filesystem │
└────────────┬───────────────┘
┌──────▼───────┐
│ Vault (.md) │
│ + Git │
└──────────────┘No database. No index. No sync. The MCP server reads and writes markdown files directly. Obsidian and Claude Code share the same folder. Git provides versioning. Scaffold files sync on server startup (commands always, schemas only if unchanged).
Testing
uv run pytest tests/ -v69 tests covering all 12 actions, including path traversal security, slug/title/alias link resolution, code block stripping, git commit with selective staging, and schema validation.
Extending
Add a new page type
Create
_schemas/mytype.yamlfollowing the existing schema formatDefine required fields, enums, defaults
The MCP server picks it up automatically on next request
Evolve the style guide
Tell Claude: "update the style guide to prefer tables over bullet lists in concept pages" — or edit _wiki/style-guide.md directly in Obsidian.
Add new slash commands
Drop a .md file in .claude/commands/. Use $ARGUMENTS to pass through user input.
Inspiration
Inspired by Andrej Karpathy's LLM Wiki pattern — the idea that an LLM should incrementally build and maintain a persistent wiki rather than re-derive knowledge from raw sources on every query.
License
MIT
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
Shared project wiki for AI agents: read and write pages, next actions, and activity logs over MCP.
Shared long-term memory vault for AI agents with 20 MCP tools.
Self-hostable team wiki; agents read & write it via MCP; Atlas turns your repo into a cited wiki.
Agent-native notes, tasks, dev-docs, vaults, sync & handoffs. MCP + OpenAPI dual surface.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceMCP server for structured markdown knowledge vaults that provides validation, FTS5 search, and wikilink cross-references. Enables AI agents to prime context and search across vaults using two MCP tools and template resources.8MIT
- AlicenseNot gradedqualityCmaintenanceEnables coding agents to maintain a folder-scoped research wiki for scientific papers by providing MCP tools for full-text search, reading, note creation, tagging, logging, and PDF ingestion, all without requiring its own LLM API key.Apache 2.0
- AlicenseNot gradedqualityNot gradedmaintenanceEnables any MCP-capable agent to write and maintain its own wiki of small linked markdown pages with a typed ontology, storing, indexing and retrieving them through keyword (BM25) search plus ontology-graph traversal, typed-relation management, page reads and writes, linting and listing. It also offers an optional vision tool that extracts objects and text from images so text-only models can learn from screenshots, charts and scans.MIT
- AlicenseNot gradedqualityBmaintenanceEnables multiple AI coding agents to share one Obsidian-compatible Markdown knowledge vault over MCP, letting them retrieve context, search, read, write, merge, lint, and verify linked pages with drift and secret detection. Supports git-based sync, local credential storage, and human editing in Obsidian or VS Code.1MIT