mcp-server-markview
MCP (Model Context Protocol) server for MarkView — a native macOS Markdown previewer.
Lets AI assistants (Claude, etc.) preview Markdown files and open them in the MarkView app directly from the conversation.
Requirements
- macOS (arm64 or x86_64)
- Node.js 18+
- MarkView.app (auto-fetched on install, or install manually from Releases)
Quick Start
Run without installing:
npx mcp-server-markview
Or install globally:
npm install -g mcp-server-markview
mcp-server-markview
The binary is downloaded automatically during installation. If the download fails (e.g. offline install), the wrapper falls back to a locally installed MarkView.app at /Applications or ~/Applications.
Claude Code Configuration
The easiest way — run once in your terminal:
claude mcp add --transport stdio --scope user markview -- npx mcp-server-markview
This writes to ~/.claude.json (user scope — works across all projects). Restart Claude Code after adding.
Or add manually to ~/.claude.json (permissions go in settings.json — MCP config goes here):
{
"mcpServers": {
"markview": {
"command": "npx",
"args": ["mcp-server-markview"]
}
}
}
Available Tools
preview_markdown
Renders a Markdown string and opens a live preview in MarkView.
content | string | Markdown source text to preview |
title | string | Optional window title |
open_file
Opens a Markdown file from disk in MarkView.
path | string | Absolute path to the .md file |
Transport
The server uses stdio transport (JSON-RPC 2.0 over stdin/stdout), which is the standard MCP transport and compatible with all MCP clients.
How It Works
npm install runs scripts/postinstall.js, which downloads the prebuilt MarkView release archive from GitHub and extracts the markview-mcp-server binary.
- The binary is placed at
bin/markview-mcp-server-binary inside the package.
bin/mcp-server-markview (the shell wrapper registered in bin) locates the binary and execs it, preserving stdio.
Troubleshooting
Binary not found after install
Re-run the postinstall script manually:
node "$(npm root -g)/mcp-server-markview/scripts/postinstall.js"
Download failed (corporate proxy / offline)
Install MarkView.app manually from the Releases page and place it in /Applications. The wrapper will find it automatically.
Permission denied
chmod +x "$(npm root -g)/mcp-server-markview/bin/markview-mcp-server-binary"
chmod +x "$(npm root -g)/mcp-server-markview/bin/mcp-server-markview"
License
MIT — see LICENSE.