How the PDF is made

The preview is rendered to an image with html2canvas and placed on PDF pages by jsPDF (through the html2pdf.js library), at the paper size, orientation and margins you choose. Because the page is captured as an image, text in the PDF is not selectable or searchable. If you need selectable text, open the HTML in your browser and use Print > Save as PDF instead.

Controlling page breaks

Long documents are split across pages automatically. To force a break, add CSS such as <div style="break-before: page"> before a section, or page-break-inside: avoid on a table row or card you want to keep together; the converter honours both the modern and legacy break properties.

Tips for good results

HTML to PDF Converter

Paste HTML or open an .html file, preview it, and download a polished PDF. Everything runs locally in your browser.

HTML source
Live preview
Ready — no data is uploaded.
About this tool

Free Online HTML to PDF Converter

Convert HTML pages, invoices, reports, templates, and formatted text into PDF files without uploading your content. Paste source code or open an HTML file, check the live preview, choose the paper format and margins, and download the result.

Common use cases

Is my HTML uploaded?

No. Rendering and PDF generation happen in your browser.

Can I use CSS in the HTML?

Yes. Inline styles and standard browser-supported CSS are included in the preview and PDF.

Can I convert a complete HTML file?

Yes. Use Open HTML file or paste its source into the editor.