Skip to content

Latest commit

 

History

History
140 lines (89 loc) · 5.63 KB

README-lite.md

File metadata and controls

140 lines (89 loc) · 5.63 KB

PyMuPDF

PyMuPDF Lite

pymupdf%2FPyMuPDF | Trendshift

Docs PyPI Version PyPI - Python Version License AGPL PyPI Downloads Github Stars Discord Forum Twitter Hugging Face

The PDF engine behind over 50 million monthly downloads, powering AI pipelines worldwide.

PyMuPDF Lite is a cut-down version of PyMuPDF without the PyMuPDF Layout engine.

Star on GitHub


Why PyMuPDF Lite?

  • Minimal
    • Reduced disc space (e.g. 25MB pymupdf-lite vs 100's of MB for pymupdf and its required packages.
    • Available for more OS's, cpus and python versions, for example:
      • Pyodide
      • Musllinux
      • MacOS-x64
      • All official python versions
  • No mandatory dependencies — pip install pymupdf-lite and you're done

Installation

pip install pymupdf-lite

Wheels are available for Windows, macOS, and Linux on Python 3.11–3.15. If no pre-built wheel exists for your platform, pip will compile from source (requires a C/C++ toolchain).

See: https://pypi.org/project/pymupdf-lite/#files for the definitive list of available wheels.

PyMuPDF Config

After installation, run the pymupdf-config command, This will review what is installed and show information about what other packages (Python and otherwise) may be available for your system and could improve accuracy and speed.

Usage

Use the API just as you would use PyMuPDF, e.g.

import pymupdf

doc = pymupdf.open("sample.pdf")
...

Supported File Formats

Input

Category Formats
PDF & derivatives PDF, XPS, EPUB, CBZ, MOBI, FB2, SVG, TXT, MD
Images PNG, JPEG, BMP, TIFF, GIF, and more

Output

Format Notes
PDF Full fidelity conversion from Office formats
SVG Vector page rendering
Image (PNG, JPEG, …) Page rasterisation at any DPI
Markdown Structure-aware, LLM-ready
JSON Bounding boxes, layout data, per-element detail
Plain text Fast, lightweight extraction

Supported Python versions

Python 3.11 – 3.15. Wheels ship for:

  • manylinux x86_64 and aarch64
  • musllinux x86_64
  • macOS x86_64 and arm64
  • Windows x86 and x86_64

Documentation

Full installation guide, API reference, cookbook, and tutorial at pymupdf.readthedocs.io.


Licensing

PyMuPDF and MuPDF are maintained by Artifex Software, Inc.

  • Open source — GNU AGPL v3. Free for open-source projects.
  • Commercial — separate commercial licences available from Artifex for proprietary applications.

Contributing

Contributions are welcome. Please open an issue before submitting large pull requests.

⭐ Support this project

If you find this useful, please consider giving it a star — it helps others discover it!

Star on GitHub