Convert HTML and CSS into a PDF

Convert an HTML file or pasted markup, plus its images and CSS, into a PDF with selectable text and links.

Free, with no sign-up and no watermark. The file is processed in your browser and never uploaded.

Turn an HTML file — or HTML code you paste in — into a PDF with selectable text, links, images, backgrounds and tables. Upload the page together with its images and CSS files so relative links resolve. Scripts in the page are not run.

Web addresses can't be converted directly, because browsers block one site from reading another. Save the page with Ctrl/Cmd + S and upload the HTML file instead.

Step by step

  1. Choose a source: Pick Upload HTML file or Paste HTML code.
  2. Add the files or code: Upload the .html file plus any images and .css files it uses, or paste your markup into the editor.
  3. Set up the page: Choose Page size, Orientation and Margins.
  4. Fit wide content: Leave Shrink wide content to fit the page ticked so wide layouts aren't cut off.
  5. Convert: Click Convert to PDF.

Handy for

Saving articles

Keep a clean copy of a saved web page for offline reading.

Email templates

Turn an HTML email or receipt into a PDF record.

Generated reports

Convert HTML reports exported by other software.

Developers

Quickly check how markup and CSS print.

Good to know

  • CSS page breaks (break-before / page-break-before) are respected.

  • Content that depends on JavaScript to appear won't be shown, because scripts are not run.

  • Links stay clickable in the PDF.

Questions

Are my files uploaded anywhere?

No. The file is read and processed by JavaScript running in your browser tab. Nothing is sent to a server, and the result is created on your device.

Is the text in the PDF selectable?

Yes. Text is placed as real text, not as a picture, so you can search, select and copy it. The exceptions are Devanagari, Chinese, Japanese, Korean and emoji characters, which are drawn as tiny images so they look right — those can't be selected.

Why can't I paste a URL?

Browsers don't allow one website to read another's pages. Save the page in your browser and upload the file.

Are web fonts used?

Text is set in embedded open fonts (sans, serif or monospace to match the page), so custom web fonts are approximated.

More Make a PDF tools

  • Markdown (.md) to PDF — Lay out Markdown headings, lists, quotes and code blocks on A4 pages as selectable text.
  • Text File (TXT) to PDF — Turn a .txt file or pasted text into A4 pages of selectable text, keeping your line breaks and wrapping long lines.
  • Type & Save as PDF — Write in the browser using # for headings and - for bullets, and save it as an A4 PDF with selectable text.
  • CSV to PDF & PDF to CSV — Turn delimited text into a bordered PDF table, or rebuild a PDF's rows and columns as a CSV file.
  • EPUB eBook to PDF — Convert DRM-free EPUB books to PDF with their styling and images, chapter page breaks and an optional cover.
  • Audio Transcript to PDF — Transcribe audio, video or a mic recording on your device with Whisper, then save it as PDF, TXT or SRT.

All Make a PDF tools