pdf-reader-mcp

by @shtse8

Pdf Reader MCP Server

Convert local PDFs, Office files, EPUBs, web pages, images, and media into token-lean, reading-order Markdown directly on your machine with no API keys. Formerly pdf-reader-mcp and now shipped as anymd, this native Rust MCP server runs over stdio for Claude Code, Cursor, Codex, and VS Code.

Files & Documents1,079rustMIT

Server facts

pdf-reader-mcp

GitHub stars

1,079

Last commit

Nov 26, 2026

Runtime

rust

License

MIT

Project

Author
shtse8
License
MIT

Tech

Runtime
rust
Transports
stdio
Remote access
No
Authentication
None (offline local binary; optional Pro account login)

Activity

GitHub stars
1,079
Last commit
Data as of

Tags

  • Nodejs
  • Stdio
  • Typescript
  • ai agent
  • llm tool
  • mcp
  • model content protocol
  • pdf
  • pdf parse
  • pdf parser
  • pdf reader

Overview

Developers searching for pdf reader mcp for Claude Code, Cursor, VS Code, or OpenCode will find that this repository—now branded `anymd`—has evolved from a PDF reader into a local Rust document-to-Markdown MCP server and CLI. Rather than relying on Python parsers, LibreOffice, or cloud APIs, its native glyph-level PDF layout engine reconstructs multi-column reading order, recovers bordered and borderless tables, strips running headers, and emits page citation anchors inside a configurable token budget (default 20,000 tokens with cursor pagination). On the open AgentDocBench suite of 38 documents, anymd scores 96.4 overall in 11.5 seconds while producing 14%–32% fewer output tokens than Docling, Kreuzberg, Unstructured, and MarkItDown.

Setup works over local stdio with no API keys required: run `npx -y @sylphx/anymd setup` (Node 18+) to register Cursor, VS Code, Claude Desktop, Claude Code, Windsurf, Codex, and Gemini CLI automatically, or install prebuilt binaries via `pip install anymd`, `uvx anymd`, Homebrew (`brew install sylphxai/tap/anymd`), Docker (`ghcr.io/sylphxai/anymd`), or `cargo install anymd`. Just 4 MCP tools (`outline`, `read`, `search`, `inspect`) cover PDF, DOCX, PPTX, XLSX/CSV, EPUB, HTML URLs, EXIF/OCR images, and audio/video subtitles or local Qwen3-ASR transcripts, with `--allow-dir=` sandboxing available to restrict file access.

Install & configure

Requirements

  • Node.js 18+ for `npx -y @sylphx/anymd` (installs platform native binary), OR Python (`pip`/`uvx`), Homebrew, Docker, or Rust 1.95+ (`cargo install`)
  • Optional local OCR via `anymd setup ocr` (~2 GB local models) or installed `tesseract`; optional `ffmpeg`/`ffprobe` for audio/video
  • Optional anymd Pro license (US$29 one-time) only if using deterministic PDF `cite_check` or video frame extraction
Documented launch / install command
npx -y @sylphx/anymd setup

Run `npx -y @sylphx/anymd setup` to configure detected MCP clients automatically (use `--client cursor,claude-code,codex` to target specific hosts), or invoke `npx -y @sylphx/anymd` manually over stdio. Pass repeatable `--allow-dir=/path/to/docs` flags or `MCP_PDF_ALLOWED_DIRS` to confine filesystem access.

Config file · macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

Use Settings → Developer → Edit Config when available. Do not assume a Linux configuration path; check the client documentation for your platform. Remote servers use the app’s connector flow when supported, not the local stdio file shown here. Merge this example with existing settings; do not overwrite unrelated servers.

Claude Desktop configuration
{
  "mcpServers": {
    "anymd": {
      "command": "npx",
      "args": [
        "-y",
        "@sylphx/anymd"
      ]
    }
  }
}

Read the Claude Desktop setup guide

Config file · Project: .cursor/mcp.json

User: ~/.cursor/mcp.json

The project path is relative to the workspace root. The tilde denotes your user home directory. Use Cursor’s MCP settings to confirm which configuration and scope your installed version is reading. Merge this example with existing settings; do not overwrite unrelated servers.

Cursor configuration
{
  "mcpServers": {
    "anymd": {
      "command": "npx",
      "args": [
        "-y",
        "@sylphx/anymd"
      ]
    }
  }
}

Read the Cursor setup guide

Config file · Workspace: .vscode/mcp.json

For user scope, use the “MCP: Open User Configuration” command if available. Do not guess a user configuration path across operating systems, profiles, containers, or remote workspaces; check the client documentation. Merge this example with existing settings; do not overwrite unrelated servers.

VS Code configuration
{
  "servers": {
    "anymd": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@sylphx/anymd"
      ]
    }
  }
}

Read the VS Code setup guide

Config file · macOS/Linux: ~/.codeium/windsurf/mcp_config.json

Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json

Open the MCP configuration through Windsurf’s settings when possible to confirm the active file. Paths can differ in managed or future releases; check the client documentation if this location is not present. Merge this example with existing settings; do not overwrite unrelated servers.

Windsurf configuration
{
  "mcpServers": {
    "anymd": {
      "command": "npx",
      "args": [
        "-y",
        "@sylphx/anymd"
      ]
    }
  }
}

Read the Windsurf setup guide

Config file · Project scope: .mcp.json at the repository root

The project file uses mcpServers. For user scope, use claude mcp add --scope user rather than assuming .mcp.json in your home directory is the user configuration. Check the client documentation for managed settings and storage details. Merge this example with existing settings; do not overwrite unrelated servers.

Claude Code configuration
{
  "mcpServers": {
    "anymd": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@sylphx/anymd"
      ]
    }
  }
}

Read the Claude Code setup guide

Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.

Tools

Source: repository README. Tool descriptions are a documented snapshot, not a live capability check.

ToolWhat it does
outlineExtracts a document's heading tree with node IDs and unit or Markdown ranges in `json` or `tree` format.
readConverts a file, web URL, or directory into paginated Markdown supporting page ranges, `max_tokens`, cursors, OCR, image refs, revisions, and transcripts.
searchSearches text across files, folders, and URLs with literal matching and automatic BM25-ranked passage fallback.
inspectRuns deeper PDF and video operations including `render_page`, `extract_regions`, `ocr_pages`, geometry `structure`, `compare`, plus Pro `cite_check` and `render_frame`.

Use cases

  • Extract multi-column academic PDFs and borderless financial tables into clean Markdown with `<!-- page N -->` anchors inside Claude Code or Cursor.
  • Search contracts or technical specs across nested folders using `search` with glob filtering and BM25 passage ranking.
  • Convert mixed project archives (DOCX tracked changes, PPTX slide decks, XLSX spreadsheets, EPUBs, and web articles) via a single MCP tool.
  • Verify PDF citations against page geometry or inspect video timelines and SHA-256-hashed frames offline with optional anymd Pro.

Strengths

  • Runs natively in Rust on local hardware with no API keys or document uploads; MIT-licensed core covers all 4 MCP tools and CLI conversion.
  • Scores 96.4 overall and 92.2 table-cell F1 across 38 AgentDocBench documents in 11.5 seconds while cutting output tokens.
  • Single `npx -y @sylphx/anymd setup` command configures Claude Code, Cursor, VS Code, Codex, Claude Desktop, Windsurf, and Gemini CLI.
  • Built-in security controls block private/loopback URL fetches, cap embedded images at 50 megapixels, and confine reads via `--allow-dir`.

Limitations

  • Recently renamed from `pdf-reader-mcp` to `@sylphx/anymd`, requiring package migration for legacy configs.
  • Deterministic PDF `cite_check` and verifiable video frame extraction (`video_timeline`, `render_frame`) require a US$29 paid anymd Pro license.
  • Local doc-VLM OCR and Qwen3-ASR transcription require explicit opt-in model downloads (around 2 GB for OCR) or local `tesseract`/`ffmpeg` binaries.

pdf-reader-mcp setup notes

  • pdf-reader-mcp's stdio example needs a client that launches local processes.

Frequently asked questions

Run `npx -y @sylphx/anymd setup` with Node.js 18+ to automatically register the stdio server across Cursor, Claude Code, VS Code, Codex, Claude Desktop, Windsurf, and Gemini CLI. If you prefer manual setup, point any MCP client to command `npx` with args `["-y", "@sylphx/anymd"]`, or run `claude mcp add anymd -- npx -y @sylphx/anymd`.

Related MCP servers