
MarkItDown-MCP
MCP微软官方出品:把 PDF、Word、Excel、PPT、HTML 等文件或网址转换为 Markdown,便于 agent 阅读与检索;只有一个 convert_to_markdown 工具,支持 STDIO 与本地 HTTP。
MarkItDown-MCP
[!IMPORTANT] The MarkItDown-MCP package is meant for local use, with local trusted agents. In particular, when running the MCP server with Streamable HTTP or SSE, it binds to
localhostby default, and is not exposed to other machines on the network or Internet. In this configuration, it is meant to be a direct alternative to the STDIO transport, which may be more convenient in some cases. DO NOT bind the server to other interfaces unless you understand the security implications of doing so.
The markitdown-mcp package provides a lightweight STDIO, Streamable HTTP, and SSE MCP server for calling MarkItDown.
It exposes one tool: convert_to_markdown(uri), where uri can be any http:, https:, file:, or data: URI.
Installation
To install the package, use pip:
pip install markitdown-mcp
Usage
To run the MCP server, using STDIO (default), use the following command:
markitdown-mcp
To run the MCP server, using Streamable HTTP and SSE, use the following command:
markitdown-mcp --http --host 127.0.0.1 --port 3001
Running in Docker
To run markitdown-mcp in Docker, build the Docker image using the provided Dockerfile:
docker build -t markitdown-mcp:latest .
And run it using:
docker run -it --rm markitdown-mcp:latest
This will be sufficient for remote URIs. To access local files, you need to mount the local directory into the container. For example, if you want to access files in /home/user/data, you can run:
docker run -it --rm -v /home/user/data:/workdir markitdown-mcp:latest
Once mounted, all files under data will be accessible under /workdir in the container. For example, if you have a file example.txt in /home/user/data, it will be accessible in the container at /workdir/example.txt.
Accessing from Claude Desktop
It is recommended to use the Docker image when running the MCP server for Claude Desktop.
Follow these instructions to access Claude's claude_desktop_config.json file.
Edit it to include the following JSON entry:
{
"mcpServers": {
"markitdown": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"markitdown-mcp:latest"
]
}
}
}
If you want to mount a directory, adjust it accordingly:
{
"mcpServers": {
"markitdown": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-v",
"/home/user/data:/workdir",
"markitdown-mcp:latest"
]
}
}
}
Debugging
To debug the MCP server you can use the MCP Inspector tool.
npx @modelcontextprotocol/inspector
You can then connect to the inspector through the specified host and port (e.g., http://localhost:5173/).
If using STDIO:
- select
STDIOas the transport type, - input
markitdown-mcpas the command, and - click
Connect
If using Streamable HTTP:
- select
Streamable HTTPas the transport type, - input
http://127.0.0.1:3001/mcpas the URL, and - click
Connect
If using SSE:
- select
SSEas the transport type, - input
http://127.0.0.1:3001/sseas the URL, and - click
Connect
Finally:
- click the
Toolstab, - click
List Tools, - click
convert_to_markdown, and - run the tool on any valid URI.
Security Considerations
The server does not support authentication, and runs with the privileges of the user running it. For this reason, when running in SSE or Streamable HTTP mode, the server binds by default to localhost. Even still, it is important to recognize that the server can be accessed by any process or users on the same local machine, and that the convert_to_markdown tool can be used to read any file that the server's user has access to, or any data from the network. If you require additional security, consider running the server in a sandboxed environment, such as a virtual machine or container, and ensure that the user permissions are properly configured to limit access to sensitive files and network segments. Above all, DO NOT bind the server to other interfaces (non-localhost) unless you understand the security implications of doing so.
Trademarks
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.
相关资源

MarkItDown
CLI把 PDF、Word、Excel、PPT、HTML、图片、音频等文件转成保留标题、列表与表格结构的 Markdown,供大模型读取与分析。微软官方维护,需要 Python 3.10 以上。
microsoft/markitdown199k
anydoc
CLIFirecrawl 出品,在本地把 Word、PPT、Excel、PDF、EPUB、RTF 等文档毫秒级转成干净的 Markdown,保留标题、表格、脚注与公式,方便 agent 读合同、讲义、报表等附件。需安装 Node.js;扫描件可选用 Firecrawl 云端 OCR(会上传整份文件)。
firecrawl/anydoc23.8k
anymd
MCP在本机把 PDF、Word、PPT、Excel、EPUB、网页和图片转成干净的 Markdown,保留页码锚点、表格与双栏阅读顺序,并能跨文件夹全文搜索,便于核对合同、卷宗与论文原文。原名 pdf-reader-mcp;文件不上传、无需 API Key,本机需 Node.js 18+,扫描件 OCR 需另装 tesseract。
SylphxAI/anymd1.1k
unoserver
CLI以常驻服务方式运行 LibreOffice,用 unoconvert 批量转换 Word、Excel、PPT、ODF 与 PDF,同样时间内可转换的文档数约为每次冷启动 LibreOffice 的 2 到 4 倍。需先安装 LibreOffice 并用其自带的 Python 安装,官方只在 Linux 上测试。
unoconv/unoserver948
Docling MCP
MCPDocling 项目官方 MCP:把 PDF、Word、PPT 等文件转成结构化文档,识别版面与表格、对扫描件做 OCR,也能让 agent 逐段生成新文档并导出 Markdown。本地模式需 Python 与 uv,首次运行会下载版面识别模型;也可改连自建的 Docling Serve 服务。
docling-project/docling-mcp806
document-skills
PluginAnthropic 官方文档技能包,也是 Claude 文件能力背后的实现:创建、编辑和分析 Word、Excel、PowerPoint 与 PDF,支持修订批注、公式和表单填写。源码公开,但不是开源许可。
anthropics/skills203k