Comparisons

Weblitz and Playwright

Playwright prints with Chrome itself, so its PDFs are Chrome's. Weblitz prints the same documents without a browser, up to 9.6× faster. measured 2026-11-25 The measurement

The numbers times measured 2026-11-25 scores measured 2026-11-19 sizes measured 2026-11-07

WeblitzPlaywright
Best case: 200 one-page letters, one threadWeblitz up to 9.6× faster1.3 ms a letter13 ms a letter
On a 2-core Linux x64 server: 200 one-page letters, one threadWeblitz up to 7.8× faster, measured 2026-11-25 in two runs, each run's time3.2 and 3.2 ms a letter25.2 and 27.1 ms a letter
The 17 bench documentsone after another177 ms562 ms
Engine on a Linux server119 MB876 MB
Docker imageWeblitz on Microsoft's .NET 10 runtime; Playwright's .NET image (mcr.microsoft.com/playwright/dotnet, v1.64.1-noble: the .NET SDK and three browsers)330 MB3.59 GB
Its PDFs beside Chrome'sthe same tool for both, the 17 documents99.9%Chrome itself

On an Apple M4 Pro laptop, .NET 10, both warm, Playwright in its open source mode (1.64.1, Chrome 156), Weblitz unlicensed. A time is the mean of two runs, the libraries in opposite orders; the best case is the measure, among those both printed in full, where Weblitz was furthest ahead, floored. Weblitz's score above is the same tool's as theirs; its own bench gives it 100% on the bench's box-by-box comparison with Chrome's own PDFs. Every measure: the run's data and the scores, page by page; how each was made: the measurements.

Where it runs, and what it costs read 2026-11-07

What each vendor's own pages say, read 2026-11-07; list prices in US dollars, excluding tax.

What Playwright does better

  • It is Chrome: its PDFs are the reference every score on this site is measured against. source
  • It is free and open source. source
  • It tests web applications in Chromium, Firefox and WebKit, clicks and types: a printing engine does none of that. source

Moving from Playwright

One HTML page to PDF bytes, before and after. Weblitz's options carry Puppeteer's page.pdf() names; nothing to download, start or keep alive.

Microsoft.Playwright
using Microsoft.Playwright;

using var playwright = await Playwright.CreateAsync();
await using var browser = await playwright.Chromium.LaunchAsync();
var page = await browser.NewPageAsync();
await page.SetContentAsync(html);
var pdf = await page.PdfAsync(new PagePdfOptions
{
    Format = "A4",
    PrintBackground = true,
    Margin = new Margin { Top = "20mm", Bottom = "20mm" },
});
Weblitz
using WeblitzPdf;

var pdf = HtmlToPdf.Render(html, new HtmlPdfOptions
{
    Format = "A4",
    PrintBackground = true,
    Margin = new HtmlMargins(Top: "20mm", Bottom: "20mm"),
}).Pdf;
dotnet add package WeblitzPdf --prerelease