Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/pymupdf/pymupdf4llm-mcp/llms.txt

Use this file to discover all available pages before exploring further.

stdio (standard input/output) transport is the simplest way to run pymupdf4llm-mcp. In this mode, the MCP server communicates directly over the process’s stdin and stdout streams. Your MCP client — such as Cursor, Windsurf, or Claude Desktop — spawns the server process automatically when it starts and shuts it down when it exits, so you never need to manage a long-running server process yourself.
Use uvx pymupdf4llm-mcp@latest to always run the latest published version without creating or maintaining a virtual environment. uvx downloads, caches, and runs the package in one step.

Launching the Server

You can start the server in stdio mode in two ways depending on whether you want to run it directly or rely on your MCP client to manage the process.
1

Run with uvx (recommended)

The fastest way to start the server with no installation required:
uvx pymupdf4llm-mcp@latest stdio
This downloads and runs the latest version of pymupdf4llm-mcp in a temporary, isolated environment.
2

Run from a local installation

If you have installed pymupdf4llm-mcp into a local environment (for example via pip install pymupdf4llm-mcp or uv add pymupdf4llm-mcp), run it directly:
pymupdf4llm-mcp stdio

Configuring Your MCP Client

Most MCP clients accept a JSON configuration block that tells them how to spawn the server process. Paste the block below into your client’s MCP server settings. The client will start the server on demand — you do not need to launch it manually beforehand.
{
  "mcpServers": {
    "pymupdf4llm-mcp": {
      "command": "uvx",
      "args": ["pymupdf4llm-mcp@latest", "stdio"],
      "env": {}
    }
  }
}
This configuration works with Cursor, Windsurf, Claude Desktop, and any other MCP client that supports the stdio transport. The command and args fields tell the client exactly what process to start; no port, URL, or network setup is needed.

No Network Configuration Required

Unlike SSE mode, stdio requires no port bindings, no firewall rules, and no reverse proxy. All communication happens through the process’s standard streams, which means the server is only accessible to the client that spawned it. This makes stdio the most straightforward option for local, single-user development.

When to Use stdio vs SSE

Choose stdio when…

  • You are working locally on a single machine
  • You want the simplest possible setup
  • Your MCP client (Cursor, Windsurf, Claude Desktop) supports stdio transport
  • You do not need simultaneous access from multiple clients

Choose SSE when…

  • You need multiple MCP clients to connect to the same server instance
  • You are deploying in a containerised or remote environment
  • You want a persistent server that outlives any single client session
  • See SSE mode for details

Build docs developers (and LLMs) love