Home / MCP / PDF Reader MCP Server
Provides a MCP server to read and extract text from PDFs from local files or URLs with standardized JSON output.
Configuration
View docs{
"mcpServers": {
"pdf_reader_local": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-v",
"/path/to/pdfs:/pdfs",
"mcp/pdf-reader"
]
}
}
}You can run a MCP server that reads and extracts text from PDF files, whether you point it at local PDFs or PDF URLs. It returns structured JSON data and handles common PDF errors, making it easy to build tools that process documents automatically.
You interact with the PDF Reader MCP Server by starting it in a way that gives it access to your PDFs and then sending it read requests from your MCP client. Use the local file mode when your PDFs live on the same machine, and use the URL mode to fetch PDFs from remote locations. Each request returns a standardized JSON response with either the extracted text or an error message.
Prerequisites You need Docker installed on your machine. You also should have access to the path where your PDFs will be stored if you plan to use the local file mode.
Install and run the MCP image locally to expose the server for your MCP client.
{
"mcpServers": {
"pdf_reader_local": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-v",
"/path/to/pdfs:/pdfs",
"mcp/pdf-reader"
],
"disabled": false,
"autoApprove": []
}
}
}{
"mcpServers": {
"pdf_reader_remote": {
"command": "docker",
"args": ["run","-i","--rm","mcp/pdf-reader"],
"disabled": false,
"autoApprove": []
}
}
}If a PDF is invalid or corrupt, missing, or cannot be fetched due to network issues, the server returns a clear error message in JSON. Successful reads include the extracted text under data.text.
The MCP server provides two endpoints for extracting text: read_local_pdf and read_pdf_url. Each returns a JSON payload with a success flag and the extracted text or an error message.
Read text content from a local PDF file. Returns a JSON object with the extracted text.
Read text content from a PDF available at a URL. Returns a JSON object with the extracted text.