Enterprise PDF for PHP
The enterprise PDF library
PHP doesn't have.
Generate archival PDF/A, sign documents with PAdES, encrypt with AES-256 and produce accessible PDF/UA from plain PHP. One memory-safe core, the same behavior as every other binding, running entirely on your servers: no per-document SaaS fees, no data leaving your network, no AGPL strings.
Install from Packagist. Pure PHP; the native core is fetched on first use.composer require rust-pdf/rustpdfWhy PHP teams pick rust-pdf
PHP runs a huge share of the world's invoicing, billing and government portals, exactly where PDF/A archival, qualified signatures, AES-256 and PDF/UA are required. Yet the classic options (TCPDF, FPDF, dompdf) predate those standards, so teams bolt on headless Chrome or pay a per-document SaaS that ships their documents off-site.
rust-pdf is one composer require using the FFI extension. The
package is pure PHP; the native core for your platform loads on first use,
and a single offline license unlocks the corporate features.
- Standards-grade, not a legacy lib: real PDF/A, PAdES and PDF/UA, not just box-and-text drawing.
- Runs on your servers: documents never leave your network and nothing phones home, ideal for LGPD/GDPR, fintech and health.
- No AGPL trap: a commercial per-application license, never the AGPL of iText or the per-server billing of Aspose.
- Deterministic output: the same input always produces the same bytes, so you can diff and audit it.
- Free to build with: everyday PDF generation is free forever; you only license the regulated-grade features.
Free to build with. Licensed when you ship.
Prototype and generate everyday PDFs for free. When you need archival, signatures, encryption or accessibility, one license unlocks them all in PHP and every other binding.
Community free
- Pages & vector graphics
- Embedded/subset fonts, Unicode shaping
- Justified paragraphs & tables
- Images (JPEG/PNG/alpha/16-bit)
- Merge / split / rotate
- Text extraction & optimize
Corporate licensed
- PDF/A: 1b / 2b / 2a / 3b / 3a archival
- Digital signatures: PKCS#7, visible & multiple
- PAdES: B-B / B-LT / B-LTA + RFC 3161 timestamps
- Encryption: RC4 / AES-128 / AES-256 (R6)
- Accessibility: Tagged PDF / PDF/UA-1
- AcroForm: fields with generated appearances
Author a tagged PDF/A in a few lines of PHP
// composer require rust-pdf/rustpdf
use RustPdf\Document;
use RustPdf\PdfaLevel;
$doc = new Document();
$doc->pdfa(PdfaLevel::A2a)->tagged()->setInfo(title: 'Q3 Report');
$f = $doc->addFontFile('Roboto-Regular.ttf');
$doc->addPage()->showText($f, 26, 72, 760, 'Annual report', 1); // H1
$bytes = $doc->toBytes(); // archival-grade, accessible PDF
The full PHP reference (fonts, images, forms, manipulation, encryption and signatures) lives in the PHP docs.
Start building in PHP
composer require rust-pdf/rustpdf and ship your first archival
PDF today. Free for everyday generation; license the corporate features when
you go to production.