C# PDF libraries compared.

Ten .NET PDF libraries measured on the same machine, under Windows and Linux, in an open benchmark: speed, throughput, memory, output correctness, fidelity to Chrome, PDF/A and PDF/UA, PDF tasks and Docker. SelectPdf maintains the benchmark and is one of the ten, so every number can be re-run and is published in full, including the measures where other libraries lead.

§THE LIBRARIES

The ten libraries.

HTML to PDF converters, PDF libraries and browser automation tools that .NET developers use to make PDFs. Each one was put through the same tasks with the version current on 2026-10-15. Licenses and prices were read on each vendor's own page on 2026-10-16.

LibraryWhat it isHTML engineLicenseEntry price
ABCpdf 14HTML to PDF and PDF libraryABCChrome146 (Chromium 146)commercial, perpetual, per computerUSD 329 (32-bit only); USD 495 Professional
Docotic.Pdf 9.9PDF library with an HTML add-onChromium 147, downloaded at run timecommercial, perpetualUSD 995 (one application); USD 1,145 (one server)
IronPDF 2026.10HTML to PDF and PDF libraryChromium 109commercial, perpetualUSD 999 (Lite)
iText 9.8 with pdfHTMLPDF library with an HTML add-onown layout engine, no JavaScriptAGPL-3.0 or commercialnot published (quote)
PDFsharp / MigraDoc 6.5PDF library and document layoutnone (no HTML)AGPL-3.0 or commercialEUR 750
Playwright 1.63browser automationChromium 153, installed separatelyMITfree
PuppeteerSharp 25.13browser automationChrome for Testing 154, downloaded at run timeMITfree
QuestPDF 2026.9documents built in C#none (no HTML)Community License or commercialfree under USD 1M revenue; USD 1,999
SelectPdf.Universal 26.5HTML to PDF and PDF libraryChromium 154, in a NuGet packagecommercial, perpetualUSD 499; free Community Edition up to 5 pages
wkhtmltopdf (WkHtmlToPdfDotNet 1.5.95)HTML to PDFQt WebKit, no longer developedLGPL-3.0free

Each library's page in the C# PDF libraries comparison on GitHub links every fact to its source and has a compiled sample for each of the 14 standard tasks.

§LEADERS

Leader of each measure.

The best value of each measure in the 2026-10-15 run, whoever holds it. There is no overall score: weigh the measures that matter for your project.

  • Fastest HTML to PDF, Windows: iText (183 ms).
  • Most conversions a minute with 8 at once, Windows: IronPDF (1,735).
  • Lowest memory with 8 at once, Windows: wkhtmltopdf (122 MB).
  • Least memory growth over 1,000 conversions, Windows: iText (-11 MB).
  • Most content checks passed, Windows: SelectPdf (96%).
  • Fastest HTML to PDF, Linux: Docotic.Pdf (107 ms).
  • Most conversions a minute with 8 at once, Linux: SelectPdf (2,597).
  • Lowest memory with 8 at once, Linux: wkhtmltopdf (194 MB).
  • Least memory growth over 1,000 conversions, Linux: iText (+6 MB).
  • Most content checks passed, Linux: SelectPdf (96%).
  • Closest to Chrome (fidelity, Windows): SelectPdf (0.984).
  • Most PDF/A, PDF/UA and PDF/X levels valid: SelectPdf (17 of 17).
  • All tag-structure checks passed: ABCpdf, SelectPdf (100%).
  • Best text extraction: SelectPdf (lowest F1 0.97).
  • Most PDF tasks offered: SelectPdf (11 of 11).
  • Smallest publish size, linux-x64: PDFsharp (2.1 MB).
§HTML TO PDF

HTML to PDF, measured.

The eight libraries that convert HTML. Values are Windows / Linux. Speed: average (geometric mean) of the median times for the 18 test pages every HTML library converted, in milliseconds, lower is better. Throughput: conversions a minute with 8 at once. Memory: peak with 8 at once, and the growth over 1,000 conversions in one process. Checks: content checks passed, such as text, images, fonts, page numbers, bookmarks and form fields. Fidelity: similarity to a Chrome screenshot of the same page, where 1.0 is identical.

LibrarySpeed, msThroughput, ×8 /minMemory ×8, MBMemory over 1,000, MBChecksFidelity
ABCpdf 14.0.6389 / 175747 / 1,9132,742 / 1,359+113 / +6343 / 43 of 480.927 / 0.924
Docotic.Pdf 9.9.19928368 / 107841 / 1,917824 / 686+178 / +26539 / 39 of 450.942 / 0.938
IronPDF 2026.10.3186 / 1691,735 / 1,520788 / 1,322+404 / +62541 / 41 of 480.928 / 0.919
iText 9.8.0183 / 262370 / 318645 / 722-11 / +639 / 39 of 480.782 / 0.782
Playwright 1.63.0280 / 1081,167 / 2,080797 / 849+26 / +28638 / 38 of 420.948 / 0.923
PuppeteerSharp 25.13.1486 / 150325 / 7981,461 / 789+259 / +28538 / 38 of 420.949 / 0.948
SelectPdf 26.5.0212 / 1341,078 / 2,597467 / 727+16 / +2046 / 46 of 480.984 / 0.984
wkhtmltopdf 1.5.95421 / 324201 / 252122 / 194+445 / +41430 / 27 of 420.809 / 0.810
§STANDARDS · PDF TASKS · DOCKER

Standards and PDF tasks.

Standards: PDF/A, PDF/UA and PDF/X levels that pass validation, out of 17 requested (veraPDF; PDF/X-1a, which veraPDF does not cover, is checked structurally). Tags: checks that tagged files really contain headings, tables, lists and figures. PDF tasks: how many of the 11 measured tasks the library offers (text extraction, search, PDF to image, Word to PDF, redaction, merge, split, watermark, digital signature, form filling, ZUGFeRD). Docker: the published app on the official mcr.microsoft.com/dotnet/runtime:8.0 image, as root and as a non-root user.

LibraryStandards validTagsText extraction (lowest F1)PDF tasksDockerPublish linux-x64, MB
ABCpdf 14.0.6256/560.178needs 14 OS packages (vendor docs)360.3
Docotic.Pdf 9.9.19928833/420.358needs 1 OS package (vendor docs)23.1
IronPDF 2026.10.3542/1120.9610root only; non-root needs 24 OS packages (vendor docs)314.6
iText 9.8.0833/420.188runs on the plain .NET image17.8
PDFsharp 6.5.0–––5runs on the plain .NET image2.1
Playwright 1.63.0–––0does not run on the plain .NET image134.9
PuppeteerSharp 25.13.1–––0does not run on the plain .NET image8.3
QuestPDF 2026.9.1–––3runs on the plain .NET image14.5
SelectPdf 26.5.017112/1120.9711runs on the plain .NET image449.6
wkhtmltopdf 1.5.95–––0does not run; the documented image does not build126.3
§CHOOSING

Which library fits.

Correct output, standards and the most PDF tasks

SelectPdf passed the most content checks (46 of 48), came closest to Chrome (0.984), produced all 17 PDF/A, PDF/UA and PDF/X levels valid, offers all 11 PDF tasks measured, completed the most conversions a minute on Linux and runs on the plain .NET Docker image. From USD 499.

Fastest HTML to PDF on Windows

iText (183 ms) and IronPDF (186 ms) had the lowest average time per page, and IronPDF completed the most conversions a minute with 8 at once (1,735). iText does not run JavaScript; IronPDF ships Chromium 109, from January 2023.

Fastest per page on Linux

Docotic.Pdf (107 ms) and Playwright (108 ms) had the lowest average time per page on Linux. Docotic.Pdf downloads its Chromium at run time and needs one OS package in Docker; Playwright needs its browser installed.

You already run browser tests

Playwright and PuppeteerSharp are free and drive a current Chrome, but they only print pages: merge, forms, signatures and PDF/A need another library, the browser has to be installed or downloaded, and neither ran on the plain .NET Docker image.

Documents built in C#, no HTML

QuestPDF (free under USD 1 million in revenue) and PDFsharp / MigraDoc (AGPL or EUR 750) lay documents out from code, run on the plain .NET Docker image and publish at 14.5 MB and 2.1 MB on Linux.

Managed code only, low-level PDF work

iText has no native code, so it runs wherever .NET runs, and it gives access to PDF objects and content streams. It is free under the AGPL; commercial prices are by quote.

Tagged PDFs on Windows servers

ABCpdf passed every tag-structure check it was given (56 of 56) and is licensed per computer: USD 329 for 32-bit processes, USD 495 for 64-bit (Professional). On Linux it needs the 14 OS packages from its documentation, and each Docker instance needs a license.

Not for new projects

wkhtmltopdf's repository is archived, its last release is from 2020, and its project page says not to use it with untrusted HTML. Its WebKit engine has not been updated since 2012; see the wkhtmltopdf alternative.

§METHOD

How it was measured.

One machine, Windows and Linux (WSL2 on the same hardware), on 2026-10-15. Each library is configured as its vendor documents and runs on its free trial or evaluation, with evaluation watermarks masked before images are compared. Times are medians of 9 rounds in a warm process. The protocol is in the methodology, the harness and test pages are in pdf-benchmarks, and every page and measure is on the full results page. Vendors can request a correction there.

?FAQ

Questions, answered.

Something else? Write to support@selectpdf.com with your settings and, if you can, the HTML.

There is no single best one; it depends on what you need. In the 2026-10-15 open benchmark, SelectPdf produced the most correct output, matched Chrome most closely, produced every PDF/A, PDF/UA and PDF/X level valid and offered all 11 PDF tasks measured; iText and IronPDF were fastest per page on Windows; Docotic.Pdf and Playwright were fastest per page on Linux; QuestPDF and PDFsharp are the smallest to deploy for documents built in code.
On Windows, iText (183 ms) and IronPDF (186 ms) had the lowest average time per page, and IronPDF completed the most conversions a minute with 8 at once (1,735). On Linux, Docotic.Pdf (107 ms) and Playwright (108 ms) were fastest per page, and SelectPdf completed the most conversions a minute with 8 at once (2,597).
Of the 17 PDF/A, PDF/UA and PDF/X levels requested, SelectPdf produced all 17 valid (veraPDF for PDF/A and PDF/UA; PDF/X-1a, which veraPDF does not cover, checked structurally), Docotic.Pdf and iText 8, IronPDF 5 and ABCpdf 2. Playwright, PuppeteerSharp, wkhtmltopdf, PDFsharp and QuestPDF were not tested on these levels.
Playwright and PuppeteerSharp are MIT licensed, and the wkhtmltopdf wrapper is LGPL. QuestPDF is free under its Community License for organisations with less than USD 1 million in annual revenue. PDFsharp and iText are free under the AGPL, which requires your own application to be AGPL too. SelectPdf's Community Edition converts HTML to PDF for free for documents up to 5 pages.
On the official mcr.microsoft.com/dotnet/runtime:8.0 image, as root and as a non-root user: SelectPdf, iText, PDFsharp and QuestPDF. ABCpdf, Docotic.Pdf and IronPDF need the OS packages from their own Docker instructions, and Playwright, PuppeteerSharp and wkhtmltopdf did not run on the plain image.
SelectPdf, which is one of the ten libraries. The harness, the test pages and the raw data are public on GitHub, every result can be re-run, and results are published in full, including the measures where other libraries lead.