obsidian-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@obsidian-mcpsearch my notes on neural networks"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
obsidian-mcp
A TypeScript MCP server that exposes your Obsidian vault to any MCP-compatible client (Claude Desktop, Claude Code, etc.) with full-text + semantic search and Anki-style spaced-repetition active recall.
Features
Capability | Tools |
Vault reading |
|
Search |
|
Active recall |
|
Question store |
|
Local embeddings —
all-MiniLM-L6-v2via@xenova/transformers. No note content leaves the machine.SQLite — FTS5 full-text index + embedding vectors (pure-JS cosine similarity fallback if
sqlite-vecis unavailable).Git sync — vault mirrored from MacBook → EC2 via git; health status reported in
get_vault_stats.SM-2 scheduler — classic SuperMemo-2 algorithm for spaced repetition.
stdio + HTTP/SSE transports — stdio for Claude Desktop, SSE for remote EC2 access.
Related MCP server: EzRAG MCP Server
Quick Start (local / Claude Desktop)
# 1. Clone and install
git clone https://github.com/YOUR_USERNAME/obsidian-mcp.git
cd obsidian-mcp
npm install
# If on Node 25+ (no prebuilt better-sqlite3 binary yet), build from source:
npm run rebuild:sqlite
# 2. Build
npm run build
# 3. Copy and edit .env
cp .env.example .env
# Set VAULT_PATH to your Obsidian vault directory
# 4. Run (stdio mode)
VAULT_PATH=/path/to/your/vault npm startClaude Desktop config
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"obsidian": {
"command": "node",
"args": ["/absolute/path/to/obsidian-mcp/dist/index.js"],
"env": {
"VAULT_PATH": "/absolute/path/to/your/vault"
}
}
}
}Environment Variables
Variable | Required | Default | Description |
| ✅ | — | Absolute path to Obsidian vault |
| No |
|
|
| No |
| HTTP port (when |
| No* | — | Bearer token for HTTP auth (*required in production) |
| No |
| SQLite database path |
| No |
|
|
| No |
| Where to cache the embedding model |
EC2 Deployment
1. Set up EC2 → GitHub SSH access
# On EC2: generate a deploy key (read-only) for the vault repo
ssh-keygen -t ed25519 -C "ec2-vault-deploy" -f ~/.ssh/vault_deploy_key -N ""
cat ~/.ssh/vault_deploy_key.pub
# Add the public key to your vault repo as a read-only deploy key on GitHub2. Run the bootstrap script
# On EC2 (as ec2-user):
export REPO_URL="https://github.com/YOUR_USERNAME/obsidian-mcp.git"
export VAULT_REPO="git@github.com:YOUR_USERNAME/obsidian-vault.git"
bash scripts/setup-ec2.shThe script:
Installs Node.js 20 via nvm
Clones vault + server repos
Builds TypeScript
Creates
.envwith a randomly generatedMCP_AUTH_TOKENInstalls and starts all systemd units (MCP server + 5-min vault sync timer)
3. Set up nginx + TLS
sudo apt install -y nginx certbot python3-certbot-nginx
# Copy config and replace domain
sudo cp nginx/obsidian-mcp.conf /etc/nginx/sites-available/obsidian-mcp
sudo ln -s /etc/nginx/sites-available/obsidian-mcp /etc/nginx/sites-enabled/
# Edit: sed -i 's/mcp.yourdomain.com/your.actual.domain/g' /etc/nginx/sites-available/obsidian-mcp
sudo certbot --nginx -d your.actual.domain
sudo systemctl reload nginx4. Mac → EC2 vault sync (auto git push)
# Edit VAULT_DIR in the plist first
nano launchd/com.obsidian.sync.plist
# Install
cp launchd/com.obsidian.sync.plist ~/Library/LaunchAgents/
launchctl load ~/Library/LaunchAgents/com.obsidian.sync.plist
# Verify
launchctl list | grep obsidian
tail -f /tmp/obsidian-sync.log5. Claude Desktop → EC2 (HTTP/SSE)
{
"mcpServers": {
"obsidian-remote": {
"url": "https://your.actual.domain/sse",
"headers": {
"Authorization": "Bearer YOUR_MCP_AUTH_TOKEN"
}
}
}
}Active Recall Workflow
User: "Quiz me on machine learning"
→ cross_question(topic="machine learning", depth="medium")
← Server returns: relevant notes + due questions
Claude reads notes, asks due questions first, then generates new ones
→ submit_review(question_id=42, grade="good")
← SM-2 schedules next review in N days
→ add_questions(note_path="ML/Backprop.md", questions=[...])
← Stored for future review sessions
User: "How am I doing on ML?"
→ get_topic_mastery(topic="machine learning")
← Stats: 23 questions, 18 reviewed, avg ease 2.3, 3 weak areasMCP Tools Reference
Vault Tools
Tool | Description |
| List notes, filter by |
| Get full note content by path or title |
| Hybrid FTS + semantic search ( |
| Semantic + tag search for a topic |
| Find notes linking to a note via |
| N most recently modified notes |
| Note count, tags, folders, git sync status |
Review Tools
Tool | Description |
| Quiz-me entry point: returns notes + due questions for a topic |
| Questions due for review today (SM-2 scheduled) |
| Record grade (again/hard/good/easy), update SM-2 schedule |
| Aggregate stats: reviewed, overdue, avg ease, weak areas |
Question Tools
Tool | Description |
| Store LLM-generated questions for a note |
| List all questions, filtered by note path |
| Remove a question from the review queue |
Architecture
obsidian-mcp/
├── src/
│ ├── index.ts # Entry point (stdio / HTTP)
│ ├── server.ts # McpServer factory
│ ├── db/
│ │ ├── schema.ts # SQLite init (FTS5, embeddings, SM-2 state)
│ │ └── sm2.ts # SM-2 algorithm
│ ├── embeddings/
│ │ └── model.ts # @xenova/transformers wrapper + cosine fallback
│ ├── vault/
│ │ ├── parser.ts # Markdown → Note (gray-matter, wikilinks, tags)
│ │ ├── indexer.ts # Full scan + chokidar file watcher
│ │ └── search.ts # FTS5 + semantic + hybrid + topic search
│ ├── tools/
│ │ ├── vault.ts # Vault reading tools
│ │ ├── questions.ts # Question CRUD tools
│ │ └── review.ts # Active recall + SM-2 tools
│ └── transport/
│ └── http.ts # Express SSE + bearer auth
├── systemd/ # EC2 systemd units + timer
├── launchd/ # Mac launchd plist (auto git push)
├── nginx/ # nginx reverse proxy config
└── scripts/
└── setup-ec2.sh # EC2 one-shot bootstrapNotes on sqlite-vec
The server automatically attempts to load the sqlite-vec native extension for vector operations. If it fails to load (e.g. on some Apple Silicon configs without Rosetta), it falls back seamlessly to a pure-JS cosine similarity implementation. This fallback works well for vaults up to ~5,000 notes; for larger vaults, ensure sqlite-vec is available.
# Test if sqlite-vec loads on your system
node -e "require('sqlite-vec')"Backups
The SQLite DB (data/obsidian-mcp.db) holds your review state — this is the only data that can't be reconstructed from the vault. Back it up:
# Manual backup
cp data/obsidian-mcp.db "data/obsidian-mcp-$(date +%Y%m%d).db"
# Cron backup on EC2 (add to crontab)
0 3 * * * sqlite3 /home/ec2-user/obsidian-mcp/data/obsidian-mcp.db ".backup '/home/ec2-user/backups/obsidian-mcp-$(date +\%Y\%m\%d).db'"License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityAmaintenanceEnables read-only access to Obsidian vaults with semantic search, tag filtering, and metadata queries. Provides secure, intelligent note retrieval and summarization for LLMs without modifying your vault.Last updated206ISC
- Alicense-qualityDmaintenanceProvides semantic search and keyword search over Obsidian notes, along with direct note retrieval, allowing external AI agents to query and access the vault.Last updated18BSD Zero Clause
- Alicense-qualityCmaintenanceEnables querying a local health knowledge base with hybrid RAG (vector + FTS5) and exploring backlinks between notes.Last updatedMIT
- Alicense-qualityCmaintenanceEnables semantic search over an Obsidian vault using natural language, retrieving relevant notes and extracted conclusions.Last updatedMIT
Related MCP Connectors
Serve a folder of Markdown notes as an MCP server: hybrid search, reading, and sourced answers.
Search your Obsidian vault to quickly find notes by title or keyword, summarize related content, a…
Connect AI assistants to your GitHub-hosted Obsidian vault to seamlessly access, search, and analy…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/AbhinavOC24/obsidian-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server