Skip to main content
Support
PDF & Documents/Convert HTML to PDF

Browse by category

All categories

Convert HTML to PDF

Convert pasted HTML or an HTML file into a PDF in your browser. Set page size, orientation and margins; H1-H3 headings become the outline. No upload.

1
Enter HTML
Paste your HTML code or open an HTML file
2
Preview
Preview the rendered output before conversion
3
Download
Download your PDF file instantly

Frequently Asked Questions

Are CSS styles preserved?

Yes. Inline and embedded CSS styles are rendered in the output PDF.

Can I select text and click links in the PDF?

Yes. Each page is drawn as a picture, and the text is laid over it as an invisible layer at the place of each line, so you can select, copy and search it. Characters outside Western European Latin (Cyrillic, Chinese, Arabic and others) stay in the picture only. Web, email links, and links to an anchor in the same document, become clickable links.

Does it follow CSS page breaks?

Yes. break-before and break-after (and the older page-break-* properties) start a new page, and break-inside avoid keeps an element on one page when it fits. Images and table rows are kept whole when they fit, and other pages end in a gap between lines. @page size and margins are not read; use the page settings instead.

Does this preserve bookmarks and form fields?

The output is a new PDF generated from your HTML. Bookmarks come from H1–H3 headings; there are no form fields unless your HTML included them.

What PDF versions are supported?

The output is generated as PDF 1.7. There is no input PDF version to consider.

Tool history

Updated Nov 16, 2026 · 4 updates
  • Nov 4, 2026fixmake HTML to PDF match its preview and survive long documents
  • Aug 10, 2026fixHTML to PDF was never functional, and repeat comparisons double-counted
  • May 8, 2026fixreplace bespoke sanitizer + drop dead pdfjs flag + tighten zip + harden HtmlToPdf
See full history →
This tool is free thanks to our sponsors.Support Loft Tools