.NET Library · v26.3 22M+ NuGet downloads · since 2014

PDF Library for .NET.
Embed it inside your .NET app.

SelectPdf is a battle-tested PDF library for .NET — convert HTML to PDF or image, extract text, merge, split and sign, all in your own process. A perpetual per-developer license, royalty-free OEM options, a free trial and a Community Edition. Targets .NET Framework 2.0+/4.0+, .NET Core and .NET 5–10.

01 / LICENSED

Commercial library

Perpetual, per-developer. Royalty-free OEM options.

  • HTML→PDF, HTML→image, PDF→text, PDF→image, merge, sign
  • .NET Framework 2.0+/4.0+, .NET Core, .NET 5–10
  • Perpetual per-developer license, royalty-free OEM options
# full PDF toolkit:
$ dotnet add package Select.Pdf
 
# free community edition HTML to PDF converter only:
$ dotnet add package Select.HtmlToPdf
.NET 5–10 .NET Framework 2.0+/4.0+ .NET Core
02 / FREE

Community Edition

Free. Generates PDFs up to 5 pages.

Functionally the full converter — the only limitation is that it generates PDF documents up to five pages. The commercial library removes that limit; swap in a license key and your existing code keeps working. C# & VB.NET samples for Windows Forms and ASP.NET are included.

§CAPABILITIES

What the .NET PDF library does.

The real feature set of the SelectPdf SDK for .NET — the same surface documented on the product reference.

01 · HTML→PDF+
HTML to PDF

Convert any web page or raw HTML string to PDF.

  • HTML5/CSS3, web fonts, @media screen & print
  • Convert a section, or exclude elements
  • HTTP headers, cookies, POST, auth, proxy
02 · HTML→Image+
HTML to image

Convert any web page or raw HTML string to an image.

  • Same rendering engine as HTML to PDF
  • Full HTML5/CSS3 & web fonts
  • Web page or raw HTML input
03 · PDF→Text+
PDF to text

Extract text from any PDF document.

  • Extract text at specific coordinates
  • Search for text in a PDF
  • Per-page extraction
04 · PDF→Image+
PDF to image

Convert PDF pages to images.

  • Render any page to an image
  • Previews, thumbnails, pipelines
  • From the same .NET library
05 · Create+
Generate & edit PDFs

Generate PDFs from scratch or load and modify existing documents.

  • Text, image, HTML, shapes, links, bookmarks
  • Document properties & viewer preferences
  • Page size, orientation, margins
06 · Pages+
Merge, split & extract

Reorganise documents at the page level.

  • Merge PDF documents
  • Split PDF documents
  • Extract pages from existing PDFs
07 · Secure+
Security & signatures

Protect and sign documents.

  • RC4 or AES encryption, up to 256-bit keys
  • User password & permissions
  • Digital signatures
08 · Stamp+
Watermarks & templates

Brand and annotate every page.

  • Watermarks and stamps
  • PDF templates repeated on all pages
  • Page numbering
09 · Forms+
Form filling

Fill PDF form fields programmatically.

  • Form filling
  • On generated or loaded PDFs
  • Combine with security settings
10 · Archive+
Accessible & archival PDF

Standards-compliant output.

  • Tagged PDF / PDF/UA-1 — accessible
  • PDF/A-3 (b, u, a), PDF/A & PDF/X
  • Modify color space, compress
11 · Chrome+
Headers, footers & breaks

Control pagination and running chrome.

  • Custom HTML headers and footers
  • Different headers/footers for specific pages
  • Auto & manual page breaks, repeat table headers
12 · Control+
Properties & control

Fine-tune the document and the conversion.

  • Document properties & viewer preferences
  • PDF open actions (open to page, run JS)
  • Multithreading support
§Quickstart · .NET

Convert HTML to PDF in C# — dotnet add to a saved PDF.

Two examples: the smallest possible document, and a real URL→PDF with options. Copy them into a fresh console app — they compile and run.

HelloPdf.cs
// create a new PDF document
SelectPdf.PdfDocument doc = new SelectPdf.PdfDocument();
// add a new page
SelectPdf.PdfPage page = doc.AddPage();

// create a font
SelectPdf.PdfFont font = doc.AddFont(SelectPdf.PdfStandardFont.Helvetica);
font.Size = 20;

// create a text element
SelectPdf.PdfTextElement text = new SelectPdf.PdfTextElement(50, 50, "Hello world!", font);
page.Add(text);

// save the pdf
doc.Save("test.pdf");
doc.Close();
HelloPdf.vb
' create a new PDF document
Dim doc As New SelectPdf.PdfDocument()
' add a new page
Dim page As SelectPdf.PdfPage = doc.AddPage()

' create a font
Dim font As SelectPdf.PdfFont = doc.AddFont(SelectPdf.PdfStandardFont.Helvetica)
font.Size = 20

' create a text element
Dim text As New SelectPdf.PdfTextElement(50, 50, "Hello world!", font)
page.Add(text)

' save the pdf
doc.Save("test.pdf")
doc.Close()
InvoicePdf.cs
using SelectPdf;

// Render a live URL — JS, web fonts, print CSS, the works.
var converter = new HtmlToPdf();
converter.Options.PdfPageSize       = PdfPageSize.A4;
converter.Options.WebPageWidth      = 1200;
converter.Options.JavaScriptEnabled = true;
converter.Options.MinPageLoadTime   = 1;
converter.Options.MaxPageLoadTime   = 60;

PdfDocument doc = converter.ConvertUrl(
    "https://yourapp.com/invoice/4821"
);

// Header on every page.
doc.Header.Height = 40;
doc.Header.Add(new PdfHtmlSection(
    0, 0, "<b>Invoice 4821</b>", "https://yourapp.com"));

doc.Save("invoice-4821.pdf");
doc.Close();
InvoicePdf.vb
Imports SelectPdf

Module InvoicePdf
    Sub Main()
        Dim converter As New HtmlToPdf()
        converter.Options.PdfPageSize       = PdfPageSize.A4
        converter.Options.WebPageWidth      = 1200
        converter.Options.JavaScriptEnabled = True

        Dim doc As PdfDocument = converter.ConvertUrl(
            "https://yourapp.com/invoice/4821")

        doc.Header.Height = 40
        doc.Header.Add(New PdfHtmlSection(
            0, 0, "<b>Invoice 4821</b>", "https://yourapp.com"))

        doc.Save("invoice-4821.pdf")
        doc.Close()
    End Sub
End Module
Invoice PDF generated from an HTML page by the SelectPdf .NET PDF library
Real PDF — generated from HTML by SelectPdf
ARCHITECTURE

The .NET PDF library, in your process.

No sidecar service, no daemon. The native rendering engine is bundled with the NuGet and runs inside your app's process on Windows.

┌─ YOUR .NET PROCESS
Input HTML / URL / raw string ConvertUrl("…")
Input Existing PDF (bytes or path) PdfDocument.Load(…)
Input Form data, certificates FillForm · Sign
◆ SELECTPDF ENGINE Native, in-process
  • · Native rendering engine, bundled in the NuGet
  • · Reads & writes PDF
  • · Runs in your process — no separate service
  • · Windows · x86 & x64 · Azure Web Apps
Select.HtmlToPdf · Select.Pdf
Output PDF document doc.Save(…)
Output PDF/A-3 · PDF/UA · PDF/X · signed Security & standards
Output Image (web page or PDF page) HTML→image · PDF→image
COMPLIANCE & SECURITY

Accessible, archival & signed PDF.

Accessibility Tagged PDF / PDF/UA-1 Logical structure tree, reading order and alt text; validated with veraPDF. Chromium & Blink engines.
Standards PDF/A-3 · PDF/A · PDF/X PDF/A-3 at levels b, u and a for long-term archiving, plus PDF/X for graphics exchange.
Encryption RC4 / AES ≤256-bit RC4 or AES encryption, up to 256-bit keys.
Access Passwords & permissions User password and document permissions.
Signatures Digital signatures Sign generated or existing documents.
Runtime Royalty-free (OEM) Perpetual, per-developer; royalty-free OEM options for unlimited deployments.
Hosting Windows · Azure Windows x86 and x64 (AnyCPU or x64); Azure Web Apps fully supported.
Forms AcroForm filling Fill form fields on generated or loaded PDFs; combine with passwords and permissions.
Branding Watermarks & page numbers Watermarks, stamps and templates repeated on every page; automatic page numbering.
DEPLOYMENT

.NET PDF Library or HTML to PDF API?

The .NET library runs in your process on Windows (x86 and x64), including Azure Web Apps. Need Linux, macOS, a non-.NET stack or zero install? The HTML to PDF API is the same engine over REST — and the same engine the free Community Edition uses. Library pricing is perpetual, from $499. Only converting web pages or HTML? See the focused HTML to PDF converter, or why it's the best HTML to PDF converter for .NET.

LIVE DEMO · NO KEY REQUIRED

Convert HTML to PDF live.

The library and the Online API share this engine. Paste a URL — we render it through the watermarked demo and hand back a real PDF, no signup, no key.

Web page options
Widthpx
Heightpx
Min loadsec
Max loadsec
Page margins
Toppt
Rightpt
Bottompt
Leftpt
Demo limits: rendered with Chromium, output capped at 5 pages, watermarked, load time clamped. The result panel shows what was clamped — remove every limit with a free API key or the .NET trial.
· ms · p · WATERMARKED DEMO
?FAQ

PDF library for .NET, answered.

More in the .NET library docs and the API reference — the rest is one email away.

The SelectPdf .NET library runs on Windows (x86 and x64), including Azure Web Apps. For Linux, macOS or a non-.NET stack, use the SelectPdf Online API — the same engine over REST.
The Select.HtmlToPdf and Select.Pdf packages bundle the native rendering engine with no external dependencies — no COM, no GAC install, no Adobe runtime and no Office automation.
The .NET library supports .NET Framework 2.0+ / 4.0+, .NET Core, and .NET 5 through .NET 10.
A perpetual, per-developer license — royalty-free OEM options available for unlimited deployments. Maintenance-plan and renewal options are available — see pricing.
Yes. The free Community Edition is functionally the full HTML to PDF converter, capped at five pages per PDF. To evaluate the full commercial library with no limits, the trial is free too — it only stamps a watermark on every page.
Yes. The .NET HTML to PDF converter and the Online API share the same rendering engine and produce the same output — pick the deployment shape that fits your stack.
Yes. JavaScript can be enabled or disabled and the conversion can be started manually from JavaScript, and pages behind authentication or a proxy server are supported.
Yes. Custom HTML headers and footers (different per page if needed), automatic and manual page breaks, and repeating HTML table headers on each page are all supported.
SelectPdf ships four rendering engines — WebKit, WebKit Restricted, Blink and Chromium. WebKit, WebKit Restricted and Chromium run on every supported framework from .NET Framework 2.0 onward. The Blink engine requires .NET Framework 4.6.1 or later (.NET Core and .NET 5–10).
Yes. SelectPdf is a full HTML to PDF converter for .NET — it converts a URL, an HTML string or a local HTML file to PDF, with full CSS and JavaScript support, custom headers and footers, and automatic or manual page breaks, all from C# or VB.NET.
Yes. SelectPdf generates tagged, accessible PDF (PDF/UA-1) and PDF/A-3 at levels b, u and a — from HTML or built programmatically — with a full logical structure tree, reading order and alternate text. Output is validated with veraPDF. Accessible and PDF/A-3 output uses the Chromium or Blink engine and is a feature of the commercial library.