PyPDF4
PDF toolkit
What it is and what it does
PyPDF4 is a pure-Python PDF manipulation library that lets you read, extract metadata from, split, merge, crop, and encrypt/decrypt PDF files without requiring external system libraries or compiled dependencies. It can work directly with file streams or in-memory StringIO objects, making it suitable for server-side PDF handling in web applications.
The package has been abandoned since its release on 2018-08-07 with no updates in 2929 days. While it carries a permissive BSD license and claims production-stable status, the lack of active maintenance means bugs are unlikely to be fixed, compatibility with newer Python versions is not guaranteed, and security issues would not be addressed. It remains in the top tier by download volume, suggesting some ongoing use despite its dormant state.
Use it for:
- Extract title, author, and other metadata from PDF files in batch processing workflows.
- Split multi-page PDFs into individual pages or merge multiple PDFs into a single document.
- Crop or resize PDF pages programmatically without external tools.
- Encrypt or decrypt PDF files for access control in document management systems.
- Manipulate PDFs entirely in memory on web servers without writing temporary files to disk.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
PyPDF4 is a pure-Python PDF toolkit for extracting document metadata, splitting and merging pages, cropping, encrypting, and decrypting PDF files without external dependencies.
No. PyPDF4 is abandoned (no updates since 2018-08-07, 2929 days ago) and high install friction makes it a risky choice for new projects. Use only if maintaining legacy code that already depends on it and cannot migrate.
Install
pypdf4 on PyPI
pip
pip install pypdf4uv
uv add pypdf4poetry
poetry add pypdf4Installing PyPDF4
Before you install
High install friction: the package has been abandoned for 2929 days with no updates since its initial release on 2018-08-07. No active maintenance or bug fixes are being applied.
License in practice
Licensed under BSD (permissive), allowing commercial and private use with minimal restrictions, though the abandoned status means no ongoing legal or security review.
Quickstart
pip install PyPDF4==1.27.0
from PyPDF4 import PdfFileReader, PdfFileWriter
with open('input.pdf', 'rb') as f:
reader = PdfFileReader(f)
writer = PdfFileWriter()
writer.addPage(reader.getPage(0))
with open('output.pdf', 'wb') as out:
writer.write(out)
Pure-Python implementation may be slow on large PDFs; no active maintenance means compatibility issues with newer Python versions are unlikely to be fixed.
Verify before relying
- Whether the package works reliably with modern Python versions given its abandoned status and lack of recent testing.
- Current real-world performance on large or complex PDF files.
- Whether in-memory StringIO-based PDF manipulation is production-ready or has known limitations.
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | abandoned — 2,929 days since the last release |
| First released | |
| Downloads | 92,220/month — #13,467 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: PyPDF4-1.27.0.tar.gz
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
pikepdfpikepdf reads, writes, repairs, and transforms…
copyleft · top 5,000 on PyPI
PyPDF3PyPDF3 is a pure-Python PDF toolkit for…
permissive · top 15,000 on PyPI
pypdfpypdf is a pure-Python library for reading,…
permissive · top 1,000 on PyPI
PyPDF2PyPDF2 is a pure-Python library for reading,…
permissive · top 1,000 on PyPI
pdftotextExtracts text from PDF files, including…
permissive · top 15,000 on PyPI
pypdftkPython wrapper that drives the pdftk binary to…
permissive · top 15,000 on PyPI
convertapiA Python client for the ConvertAPI online file…
permissive · top 15,000 on PyPI
borbborb reads, writes, and manipulates PDF files…
agpl · top 15,000 on PyPI
python-documentcloudA Python wrapper for the DocumentCloud API that…
permissive · top 15,000 on PyPI
pdfrwpdfrw reads, writes, and manipulates PDF files…
permissive · top 5,000 on PyPI