# wkhtmltopdf

> Convert HTML to PDF using Webkit (QtWebKit)

Source: https://talira.ai/catalog/wkhtmltopdf-tky2wwnr
Every listing: https://talira.ai/catalog.md

Status: wkhtmltopdf's makers archived or ended it on 2 Jan 2023. Source: https://github.com/wkhtmltopdf/wkhtmltopdf

- Kind: Open source
- Types: Command-line tool
- Categories: [documents / pdf / generation](https://talira.ai/categories/documents/pdf/generation), [developer tools / cli](https://talira.ai/categories/developer-tools/cli)
- Platforms: linux, macos, windows, cli
- Licence: LGPL-3.0
- Pricing: Free and open source
- Free tier: yes
- Self-hostable: yes
- Creator: Ashish Kulkarni (maintainer, per wkhtmltopdf.org)
- Archived on GitHub

wkhtmltopdf and wkhtmltoimage are command-line tools that render HTML to PDF and images with the Qt WebKit engine, headless and without a display. The project is unmaintained: its [GitHub](https://talira.ai/catalog/github-ppcgj756.md) repository is archived, it depends on Qt 4 (unsupported since 2015) and an old QtWebKit with no upstream, and its own site warns never to use it with untrusted HTML because that can lead to complete takeover of the server. Its site recommends [WeasyPrint](https://talira.ai/catalog/weasyprint-c7dnxd3b.md) or [Prince](https://talira.ai/catalog/prince-cbgkkxts.md) for HTML you control and [Puppeteer](https://talira.ai/catalog/puppeteer-vbv4zakx.md) for JavaScript-heavy pages.

## Links

- Website: https://wkhtmltopdf.org
- GitHub: https://github.com/wkhtmltopdf/wkhtmltopdf
- Docs: https://wkhtmltopdf.org/usage/wkhtmltopdf.txt

## Problems it solves

- our old Rails app shells out to a WebKit-based binary for PDFs and I need to know what to replace it with
- CSS flexbox and grid don't render in our PDFs because the engine is ancient
- security scan flagged the HTML to PDF binary in our image as unmaintained
- PDF generation breaks on the new Debian base image because the binary needs old Qt libraries
- convert an HTML page to PDF with a single shell command on a server with no display
- migrating off a deprecated HTML to PDF command-line tool without rewriting all our templates
- users can put their own HTML into documents and I'm worried about server-side request forgery
- modern JavaScript in our report page doesn't run when it's converted to PDF

## Features

- HTML to PDF and image from the command line
- headless, no display server needed
- wkhtmltoimage for image output

## Capabilities

- Has a command line tool: plan not known

## Trust

Overall: 0.11 out of 1.
Signals: maintenance 0.00, adoption 0.83, momentum 0.56, community 0.78, backing 0.20, extensibility 0.20.

- 14.5k GitHub stars
- 90 contributors
- created by Ashish Kulkarni (maintainer, per wkhtmltopdf.org)

Warnings:

- archived by its makers since 2 Jan 2023
- GitHub repository is archived

## Alternatives

- [ironpress](https://talira.ai/catalog/ironpress-g94sb527.md): HTML to PDF. In process. In pure Rust.
- [DocRaptor](https://talira.ai/catalog/docraptor-qrzzachz.md): The World's Most Advanced HTML to PDF API
- [WeasyPrint](https://talira.ai/catalog/weasyprint-c7dnxd3b.md): Renders HTML and CSS to PDF, from Python or the command line
- [Prince](https://talira.ai/catalog/prince-cbgkkxts.md): Convert HTML to PDF. Beautiful printing with simple CSS.
- [Puppeteer](https://talira.ai/catalog/puppeteer-vbv4zakx.md): JavaScript API for Chrome and Firefox
- [Playwright](https://talira.ai/catalog/playwright-r7fvkefh.md): Fast and reliable end-to-end testing for modern web apps
