iLoveMyFile

HTML to PDF

Turn an HTML file or pasted HTML code into a PDF with sharp, selectable text.

HTML

Convert HTML to PDF

Drag and drop an .html file here, or choose one from your device.

Processing happens in your browser. Your file is not uploaded.
Or paste HTML

Choose an .html file or paste HTML, then preview it.

How to convert HTML to PDF

  1. Choose an .html file, or paste your HTML code and click Preview.
  2. Check the preview.
  3. Click Save as PDF. In the window that opens, choose Save as PDF as the printer or destination, then save.

What is supported

Your HTML is laid out by the browser itself, so CSS, web fonts, tables, images and every language are handled the way they are on a normal web page. Text in the PDF stays sharp and selectable. For safety, JavaScript inside the HTML is not run, so pages that build their content with scripts will appear empty. Images and stylesheets are loaded only if they use full web addresses (https://…).

Frequently asked questions

Can I convert a web page by its address?

Not with this tool. Open the page in your browser and save it as an .html file, or copy its HTML source, then convert that.

Why are my images missing?

Images with relative paths such as "images/logo.png" cannot be found, because only the HTML file is loaded. Use full addresses starting with https://, or embed the images in the HTML.

How do I control page size and margins?

In the save window, choose the paper size, margins and orientation. You can also set them in your HTML with a CSS @page rule.

Background colours are missing in the PDF.

Turn on "Background graphics" in the save window. Browsers leave backgrounds out by default to save ink.

Why does a print window open?

The PDF is made by your browser's built-in PDF engine, which gives sharp, selectable text in every language. Choosing "Save as PDF" in that window saves the file instead of printing it. You can also set the paper size, margins and orientation there.

Are my files uploaded to a server?

No. Your file is converted in your browser and never leaves your device.