All How-To Guides

3 Ways to Edit PDFs with Claude Code

How to edit PDF with Claude Code?

3 MCP servers featured

Last reviewed June 2026

Claude Code can work with PDFs out of the box. Its Read tool opens PDF files directly (around 20 pages per call), and Anthropic's official PDF skill uses Python libraries like pypdf and reportlab to merge, split, rotate, watermark, fill forms, extract text, and create new PDFs. MCP servers such as Microsoft's MarkItDown add bulk PDF-to-Markdown conversion. Here are the best options.

Recommended MCP Servers

MarkItDown

microsoft/markitdown

>80k

Official Microsoft library that converts PDFs and many other file formats to Markdown for LLM consumption.

Key Features

  • Converts PDF, Word, Excel, PowerPoint to Markdown
  • Preserves document structure (headings, lists, tables)
  • Supports local and remote files
  • Official Microsoft AutoGen team maintenance

Installation

pip install 'markitdown[all]'

MarkItDown is the go-to choice for reading PDFs with Claude. It's officially maintained by Microsoft, has excellent format support, and converts documents into clean Markdown that Claude can easily understand and work with.

Best for: Content extraction and document analysis View on GitHub

Markdownify MCP

zcaceres/markdownify-mcp

>2k

MCP server that converts various file types including PDFs, images, audio, and web content to Markdown.

Key Features

  • Converts PDF, DOCX, XLSX, PPTX to Markdown
  • Image OCR and audio transcription support
  • YouTube video transcript extraction
  • Web page to Markdown conversion

Installation

pnpm install && pnpm run build

Markdownify is a versatile MCP server that handles not just PDFs but images, audio, and web content. It's perfect if you work with diverse document types and want a single solution. The audio transcription and YouTube support make it particularly useful for multimedia workflows.

Best for: Multi-format document workflows View on GitHub

MCP Pandoc

vivekVells/mcp-pandoc

>400

Document format conversion using Pandoc, supporting bidirectional conversion between Markdown, HTML, PDF, DOCX, and more.

Key Features

  • Bidirectional format conversion (read and write)
  • Supports Markdown, HTML, PDF, DOCX, EPUB, LaTeX
  • Reference document styling for DOCX output
  • Pandoc filters and defaults file support

Installation

pip install mcp-pandoc

MCP Pandoc leverages the powerful Pandoc converter to handle bidirectional document conversions. Unlike read-only solutions, it can also generate PDFs and DOCX files from Markdown. Ideal for workflows that need both reading and writing document formats.

Best for: Document format conversion workflows View on GitHub

Quick Comparison

MCPStarsBest ForProsCons
MarkItDown84k+PDF readingOfficial Microsoft supportRead-only
Markdownify MCP2k+Multi-formatImages, audio, web supportMore complex setup
MCP Pandoc468Format conversionBidirectional conversionRequires Pandoc installed

Getting Started

To get started with PDF editing in Claude Code:

  1. For reading PDFs, install MarkItDown:

    pip install 'markitdown[all]'
    
  2. For converting PDFs to other formats, install MCP Pandoc:

    pip install mcp-pandoc
    
  3. Add to your Claude Code config and start working with PDFs.

Example prompt: "Convert this PDF to Markdown and summarize the key points."

Related Guides

Frequently Asked Questions

Can Claude Code edit PDFs natively?

Yes. Claude Code reads PDFs with its built-in Read tool (around 20 pages per call), and for editing it uses Anthropic's official PDF skill, which runs Python libraries like pypdf, pdfplumber, and reportlab. This lets Claude merge, split, rotate, watermark, fill forms, extract text, and generate new PDFs entirely in code.

How do I fill out a PDF form using Claude?

Ask Claude Code to fill the form and it uses pypdf to write values into the document's interactive form fields, then saves a new copy. Give it the PDF and the field values, such as a name, date, and address. For flat PDFs without real form fields, Claude overlays text at set coordinates using reportlab instead.

What is the best MCP server for reading PDFs with Claude?

Microsoft MarkItDown is the most popular option, exposed as an MCP server via the markitdown-mcp package (pip install markitdown-mcp). It converts PDFs, Word, Excel, and PowerPoint into clean Markdown that Claude reads easily, though it is read-only. Since Claude Code reads PDFs natively and the official PDF skill handles editing, an MCP server is mainly useful for bulk conversion.

Can Claude merge or split PDF files?

Yes. Using Anthropic's official PDF skill, Claude Code merges multiple PDFs into one file or splits a PDF into per-page or per-section files via the pypdf library. Point it at the files and describe the result you want, such as combining three reports or extracting pages 5 to 10. The same skill also rotates pages, watermarks, and encrypts PDFs.

Keep Exploring

WebMCP Developers