← Back to MinerU MCP Server

Install MinerU MCP Server

Pick your client, copy the command, done.

1

Add it to Claude Code

claude mcp add -e "MINERU_API_KEY=${MINERU_API_KEY}" mineru-mcp -- mineru-mcp-server
Required:MINERU_API_KEY+ 4 optional

Environment Variables

Set these before running MinerU MCP Server.

VariableDescriptionRequired
MINERU_API_KEYMinerU API key obtained from the official websiteYes
MINERU_API_BASEBase URL for the remote MinerU APINo
OUTPUT_DIRDirectory path where converted results are savedNo
USE_LOCAL_APIToggle to use a local MinerU API instanceNo
LOCAL_MINERU_API_BASEURL for the local API instance when USE_LOCAL_API is trueNo

Available Tools (2)

Once configured, MinerU MCP Server gives your AI agent access to:

parse_documentsConvert files to Markdown, supporting local paths and URLs with batch processing capabilities.
file_sourcesenable_ocrlanguagepage_ranges
get_ocr_languagesRetrieve the list of languages supported by the OCR engine.

Try It Out

After setup, try these prompts with your AI agent:

Convert the PDF file located at /documents/report.pdf into Markdown format.
Convert this URL https://example.com/presentation.pptx to Markdown and enable OCR for English text.
Get the list of all languages currently supported by the OCR engine.
Convert the first 5 pages of /data/manual.pdf to Markdown using the Chinese language setting.
Prerequisites & system requirements
  • An MCP-compatible client (Claude Code, Cursor, Windsurf, Claude Desktop, or Codex)
  • Python 3.8+ with pip installed
  • MINERU_API_KEY — MinerU API key obtained from the official website
Alternative installation methods

Source

git clone https://github.com/Tongzhao9417/mineru_mcp.git && cd mineru_mcp && pip install -e .
Conare · memory for coding agents

Keep this setup from going cold

Save the docs, env vars, and workflow around MinerU MCP Server in Conare so Claude Code, Codex, and Cursor remember it next time.

Remember this setup$npx conare@latest