- Home
- PDF Creation Software
- WeasyPrint
WeasyPrint
What it is
WeasyPrint is free, open-source software for web developers who need to turn HTML pages into PDF documents. It accepts HTML, CSS, local files, URLs, file objects, HTML strings, raster images, and SVG. The Python library can render an HTML object with HTML.write_pdf(), while the command-line interface supports PDF/A, PDF/UA, and PDF/X options. Sample outputs include reports, invoices, tickets, books, letters, and posters. WeasyPrint offers an API, fillable form creation, and self-hosted deployment. Documentation covers Linux, macOS, and Windows installation, plus use as a Python library, community Docker images, and an AWS Lambda layer. The default HTTP client does not handle cookies or authentication, although a custom URL fetcher can be supplied. Untrusted HTML or CSS may create security problems. Version 70.0 requires Python 3.10 or later and Pango 1.44 or later. CourtBouillon offers paid assistance, while free and open-source software remains available at no cost.
For and against
For
- Free and open-source software
- Python API renders HTML to PDF
- Supports PDF/A, PDF/UA, and PDF/X
- Runs on Linux, macOS, and Windows
- Supports fillable form creation
Against
- Default HTTP client lacks cookies and authentication
- Untrusted HTML or CSS may create security problems
- Version 70.0 requires Python 3.10 and Pango 1.44
The verdict
WeasyPrint provides a no-cost route from HTML and CSS to PDF, with Python, command-line, and self-hosted options. Review security and dependency requirements before deployment.
Who it suits
It suits web developers creating PDFs from web content, including reports and invoices. Teams needing self-hosted deployment or Python integration can use its documented options.
Plans and prices
Free and open source
Free and open source software
Read 7 Oct 2026 · weasyprint.org
Basic consulting
1 topic per month · Reply within 1 working day · Mail only · Not available in Canada and USA
Read 7 Oct 2026 · weasyprint.org
Essential consulting
3 topics per month · Reply within 1 working day · Mail and 30-minute video call per topic · Not available in Canada and USA
Read 7 Oct 2026 · weasyprint.org
Premium consulting
5 topics per month · Reply within 1 working day · Mail and 30-minute video call per topic · Not available in Canada and USA
Read 7 Oct 2026 · weasyprint.org
On the record
- Creator and maintainer
- WeasyPrint was created and developed by Kozea, while CourtBouillon provides professional support, maintenance, and community management.weasyprint.org · read 7 Oct 2026
- Dependencies
- WeasyPrint 70.0 requires Python 3.10 or later and Pango 1.44 or later, among other dependencies.doc.courtbouillon.org · read 7 Oct 2026
- Integrations
- The documentation describes use as a Python library and lists community-maintained Docker images and an AWS Lambda layer.doc.courtbouillon.org · read 7 Oct 2026
- Intended users
- The maker describes WeasyPrint as a solution for web developers and shows document examples including statistical reports and invoices.weasyprint.org · read 7 Oct 2026
- Notable limit
- The default HTTP client does not support cookies or authentication, though a custom URL fetcher can be used.doc.courtbouillon.org · read 7 Oct 2026
- Output examples
- The maker shows reports, invoices, tickets, books, letters, and posters as sample documents.weasyprint.org · read 7 Oct 2026
- PDF options
- The command-line interface supports PDF variants including PDF/A, PDF/UA, and PDF/X options.doc.courtbouillon.org · read 7 Oct 2026
- Platform support
- The documentation gives installation instructions for Linux, macOS, and Windows.doc.courtbouillon.org · read 7 Oct 2026
- Purpose
- WeasyPrint is free and open source software that helps web developers create PDF documents from HTML pages.weasyprint.org · read 7 Oct 2026
- Python API
- The Python library can render an HTML object to a PDF file with HTML.write_pdf().doc.courtbouillon.org · read 7 Oct 2026
- Security
- The documentation warns that using WeasyPrint with untrusted HTML or CSS may cause security problems.doc.courtbouillon.org · read 7 Oct 2026
- Support
- CourtBouillon offers professional assistance with WeasyPrint use, configuration, integration, bug fixes, new features, and templating.weasyprint.org · read 7 Oct 2026