
The C# PDF Library
IronPDF is the leading C# PDF library for generating and editing PDFs. Its user-friendly API allows developers to rapidly deliver professional, high-quality PDFs from HTML in .NET projects.
HTML to PDF
using IronPdf;
var renderer = new ChromePdfRenderer();
var pdfFromUrl = renderer.RenderUrlAsPdf("https://ironpdf.com/");
pdfFromUrl.SaveAs("website.pdf");
var pdfFromHtmlFile = renderer.RenderHtmlFileAsPdf("design.html");
pdfFromHtmlFile.SaveAs("markup.pdf");
var pdfFromHtmlString = renderer.RenderHtmlAsPdf("Hello World
", "C:/assets/");
pdfFromHtmlString.SaveAs("markup_with_assets.pdf");

C# PDF Library that prioritizes accuracy, ease of use, and speed.
When you need your PDF to look like HTML, fast.
Pixel-perfect rendering
What you see in the browser is what you will get in the PDF.
Cross-platform
Works on almost all platforms

Up & running in 5 mins
From the first download to working in production, in literally 5 minutes.
Key Compatibility
.NET Versions:
- C#, VB.NET, F# Languages
- .NET Core (8, 7, 6, 5, and 3.1+)
- .NET Standard (2.0+)
- .NET Framework (4.6.2+)
.NET Project Types:
- Web (Blazor & WebForms)
- Desktop (WPF & MAUI)
- Console (App & Library)
App Environments:
- Windows (10+, Server UI 2012+, Server Core 2022)
- Linux (Ubuntu, Debian, CentOS, etc.)
- Mac (macOS 10+)
- Docker (Windows, Linux, Azure)
- Azure (VPS, WebApp, Function)
- AWS (EC2, Lambda)
IDEs:
- Microsoft Visual Studio
- JetBrains Rider & ReSharper
OS & Processors:
- Windows, Mac, Linux
- x64, x86, ARM
- Binary Certification
- DigiCert Signed Binaries
Generating PDFs
HTML to PDF:
- HTML File to PDF
- HTML String to PDF
- URL to PDF
Content Pages to PDF:
- Razor to PDF (Blazor Server)
- CSHTML to PDF (MVC, Razor)
- ASPX to PDF (WebForms)
- XAML to PDF (MAUI)
PDF File Conversion:
- Images to / from PDF
- DOCX to PDF (Microsoft Word)
- RTF to PDF (Rich Text Format)
- MD to PDF (Markdown)
- PDF to HTML
Supports:
- UTF-8 Character Encoding
- Base URLs & Asset Encoding
- TLS Website & System Logins
- Async & Multithreading
- Custom Logging
- Cookies
Formatting PDFs
Use HTML Assets:
- HTML (5 and below)
- CSS (Screen & Print)
- Images (jpg, png, gif, tiff, svg, bmp)
- JavaScript (Custom Render Delays)
- Fonts (Web & Icon)
Apply Page Templates:
- Add Headers & Footers
- Add Page Numbers
- Add Page Breaks
- Fit to Paper & Zoom
- Custom Margins
Apply Page Settings:
- Responsive Layouts
- Custom Paper Size
- Orientation & Rotation
- Color
Supports PDF Standards:
- PDF Versions (1.2 – 1.7)
- PDF/UA (PDF/UA-1)
- PDF/A (PDF/A-3b)
Editing
PDFs
Set Properties & Security:
- Set Password & Permissions
- Digital Signatures (.pfx, .p12)
- PDF File Compression
- Edit PDF Metadata
- Edit & Sign Revision History
Edit Document Structure:
- Add, Copy, & Delete Pages
- Merge & Split PDFs
- Annotations
- Attachments
- Bookmarks and Outline
Edit Page Content:
- Draw Text & Bitmap
- Find and Replace Text
- Headers & Footers
- Stamp Text & Images
- Custom Watermarks
- Backgrounds & Foregrounds
Use PDF Forms:
- Create & Edit Forms
- Fill Existing Forms
View, Read, & Print PDFs:
- IronPDF Viewer
- Print to a Physical Printer
- Extract PDF Text & Images