nupdf / compare

nupdf, compared with the other ways to handle a PDF.

PyMuPDF, pypdf, pdfplumber, PDFium, Poppler and PDF Oxide, measured the same way, with the places nupdf is not the best left in.

These are measurements, not a ranking. Each tool is good at something, and the last section says when to pick one of the others.

With an agent

Thirty graded tasks, five runs each, one small-model agent a run, each allowed its own tool only: 1,045 runs. The graders use pdftotext, qpdf and MuPDF, never nupdf.

How the agent handled the PDFsRuns passedTokensTime
nupdf, over MCP
150 / 1508,98813 s
nupdf, over the CLI
150 / 15014,57816 s
pymupdf4llm with PyMuPDF, in Python
147 / 15012,80523 s
pypdf and pdfplumber, in Python
145 / 15011,82321 s
PDF Oxide, in Python
108 / 15020,85830 s
PDF Oxide's MCP server
79 / 10515,43620 s
pymupdf4llm-mcp
38 / 1054,61723 s
The model reading page images
75 / 8517,40212 s

Tokens and wall time are medians over passed runs. Tools that cannot write a PDF skip the tasks that need one. Over the CLI, nupdf used slightly more tokens than the two Python arms. Tasks, graders and every run

One call

The text of every page, as a new process, start-up included: the median over 200 test files.

ToolTime for one callPeak memoryRight text
nupdf
10.8 ms6.5 MB162 / 162
PDF Oxide pdf-oxide
11.9 ms10.8 MB157 / 162
MuPDF mutool
11.9 ms5.6 MB161 / 162
Poppler pdftotext
23.4 ms10.4 MB160 / 162
PDF Oxide Python
46.3 ms30.3 MB157 / 162
pypdf
83.8 ms37.7 MB156 / 162
PDFium pypdfium2
84.2 ms40.5 MB162 / 162
pdfminer.six
84.6 ms35.6 MB151 / 162
MuPDF PyMuPDF
84.7 ms55.6 MB162 / 162
pdfplumber
84.8 ms36.3 MB155 / 162

A long document

Pages a second over 17 documents of about 100 pages.

ToolPages a secondPeak memoryCompleted
nupdf 8 threads
2,72932.0 MB30 / 30
nupdf
1,56813.0 MB30 / 30
Poppler pdftotext
1,07213.5 MB30 / 30
PDFium pypdfium2
75752.1 MB30 / 30
MuPDF mutool
49810.0 MB30 / 30
PDF Oxide pdf-oxide
34229.1 MB30 / 30
PDF Oxide Python
31847.5 MB30 / 30
MuPDF PyMuPDF
30559.3 MB30 / 30
pypdf
18844.7 MB21 / 30
pdfminer.six
10542.6 MB23 / 30
pdfplumber
6984.1 MB20 / 30

Measured on one Apple silicon Mac, an M5 Max, on 14 November 2026, with nupdf 0.1.0, MuPDF 1.28.6 and PDF Oxide 0.3.78. Method, versions and caveats

When to pick something else

  • You are writing Python and want a library, not a tool. PyMuPDF and pypdf are libraries with years of answers behind them. nupdf is a binary, an MCP server and a Rust crate.
  • You need the least memory. MuPDF's own mutool used less than nupdf in both tables.
  • You need a layout model. For reading order on complex pages, or tables in scans, a tool built on one will do better than nupdf, whose layout is MuPDF's heuristics.
  • You need another language. PDF Oxide has bindings for several; nupdf has Rust and the command line.
  • You have one short PDF that is mostly charts. Let a vision model read the pages.

When nupdf fits

  • An agent is doing the work, and you want it to cite where an answer came from.
  • The file has to change: merged, filled, cleaned or redacted, with the result checked.
  • There are many files, or long ones, and reading them whole costs too much.
  • The files come from outside and may be damaged or hostile.
Open source, AGPL-3.0. Derived from MuPDF by Artifex Software, Inc.
DocsGitHubcrates.iollms.txt