Skip to content
Lamina PDF
Unreleased

These docs describe changes that aren’t released yet. For the newest release, see the released docs.

Lamina PDF

Create, read, edit and save PDFs from Rust and TypeScript. One core runs on servers, in browsers and at the edge.

Lamina PDF creates, reads, edits and saves PDFs. One Rust core does the work, and it runs natively and as WebAssembly in browsers, Node, Deno, Bun and Cloudflare Workers. It’s for apps that make documents, such as invoices, reports and tickets, and for apps that open documents other people send.

  • laminapdf on crates.io is the Rust crate. Its API reference is on docs.rs.
  • @laminapdf/sdk on npm is the TypeScript API over the WebAssembly build. After one await init(), every call is synchronous, and the API is the same in every runtime. Its API reference is on this site.
Area What you get Guide
Generate Pages, text with shaping, bidi and line breaking, embedded and subset fonts, the standard 14, vectors, colour, images, tagged PDF Fonts and text, Images and vectors
Navigate Links, named destinations, outlines, page labels, Info and XMP metadata Links, outlines and metadata
Edit Ops in transactions, undo and redo, incremental or full saves that respect signatures Edit a PDF, Save a PDF
Read safely Repair of damaged files as warnings, resource limits, strict mode, passwords Open password-protected files, Open files you don’t trust
Errors One coded error and warning shape on every surface Errors and warnings

Every code block on this site is a tested example file, so the code you see is the code that runs. Each example writes the same bytes in Rust and in every JavaScript runtime.

Start with your first PDF, then read how Lamina PDF thinks about a PDF. When you’re ready for your own setup, pick your runtime.