HTML to PDF

Save an HTML file as a PDF document. Page size and margins are adjustable.

Upload an HTML file

HTML, HTM

or upload from

HTML to PDF online — what you need to know

Convert HTML to PDF online when a report, invoice, price list or manual in HTML needs to become a document for sending and printing. Upload an .html or .htm file, choose the page size, orientation and margins, and download the PDF. The service applies the CSS styles written in the file itself, including print styles, and splits a long document into pages on its own. Cyrillic is supported.

When it helps

  • Save a report or export that an app or service generates in HTML as a PDF.
  • Make a PDF version of an invoice, acceptance certificate or price list laid out in HTML from a template.
  • Prepare documentation or a manual saved as a single HTML file for printing.
  • Send colleagues an HTML document in a format that opens on any device.

Images, styles and fonts

Only what’s inside the file itself is used: styles in the <style> tag and style attributes, plus images and fonts embedded as data: URIs. External resources — links to websites, neighboring files and folders — aren’t loaded: styles from external CSS won’t apply, and an image is replaced by its caption from the alt attribute, if there is one. So a page saved from a browser together with a resources folder will come out without images.

Page size and margins

A4, A3 and Letter pages are available in portrait or landscape orientation. Page margins: “Standard” is 20 mm, “Narrow” 10 mm, “No margins” 0 mm.

Page breaks and print styles

Styles from the @media print block are applied, so the document comes out the way it was designed for print. To start a section on a new page, add the CSS property break-before: page to it.

Limits and watermark

HTML files up to 50 MB on the Free plan, up to 200 MB on Pro and up to 500 MB on Business. On the Free plan, a small “Сделано в SmartPDF.ru” (“Made with SmartPDF.ru”) label is added in the corner of the pages; on Pro and Business there’s no mark.

Frequently asked questions

Can I save a website from a link?

No, only an uploaded HTML file is converted.

What about external styles, images and fonts?

They are not loaded. Styles inside the file (the <style> tag, the style attribute) are applied, as well as images and fonts embedded as data: URIs.

Is JavaScript executed?

No. The static HTML content is converted.

Why does the PDF show gibberish instead of Cyrillic letters?

Most likely, the file isn’t saved in UTF-8 but in, say, windows-1251, and the encoding isn’t declared in it. Add the tag <meta charset="windows-1251"> to the head section, or re-save the file in UTF-8 and upload it again.

How do I make one PDF from several HTML files?

Convert each file to PDF, then combine them with “Merge PDF”.

Can I upload a file from Yandex Disk?

Yes: below the file picker there is a “Yandex Disk” button. Public disk.yandex.ru links work too.