Skip to content

Convert HTML to PDF

Turn an HTML file — or markup you paste in — into a paginated PDF that looks exactly like the page: flexbox, grid, gradients, images and typography all intact.

  • Deleted right after converting
  • Encrypted transfer, deleted instantly
  • No signup, no watermark

How it works

1

Add HTML

Drop an .html file, or paste your markup into the box.

2

Choose the page

Page size, orientation and margins — applied as real print CSS.

3

Convert and download

Rendered and paginated exactly as Print → Save as PDF would, with real selectable text.

What the page is allowed to reach, and what CSS controls

The conversion has no network access and runs no scripts, and both are security decisions rather than missing features. A converter that fetched whatever a submitted page asked for would happily be pointed at addresses only our server can see, and one that ran scripts would be running a stranger's code. So a stylesheet linked to a CDN does not arrive, an image with an ordinary web address does not load, a web font is silently replaced, and a page that draws itself with JavaScript converts as whatever the markup says before anything runs. The fix is always the same: inline the CSS in a style block and embed images as data URIs. Browsers offer this directly — "Save Page As → Web Page, Complete" in Firefox, or "Save as MHTML" — and a saved single-file page converts faithfully.

Print CSS is what actually governs the result, which is the second thing worth knowing. The page is laid out as if printing, so a @media print block takes effect and an ordinary screen stylesheet may not — which is why a page with a print rule hiding its navigation converts beautifully and one without it brings the whole site chrome along. @page controls the paper: size, orientation and margins are read from it. break-before, break-after and break-inside: avoid decide where pages divide, so a table that must not split or a section that must start on a fresh page is entirely within your control.

Backgrounds are the classic omission. Browsers do not print background colours and images by default, so a dark header can convert as white unless the stylesheet says -webkit-print-color-adjust: exact — one line, and it is the difference between a branded document and a bare one. Text stays real text, links stay working links, and headings can become PDF bookmarks where the markup uses genuine heading elements.

If our server is unreachable the page says so and rebuilds the document locally, which keeps the text, the images and simple layout while simplifying anything that needs a real layout pass — grid, flexbox, floats and positioning among them. A simple document converts almost identically; a designed one does not.

When you want something else

To convert a live URL — something this page deliberately cannot do — the same kind of rendering is one command away: chrome --headless --disable-gpu --print-to-pdf=out.pdf https://example.com loads the page with its network intact, scripts and all. That is the whole difference, and it is the reason to reach for it.

For real control over headers, footers, page numbers and margins, WeasyPrint and Prince implement the CSS Paged Media specification properly: running headers from @top-center, page counters, footnotes and cross-references that resolve to page numbers. WeasyPrint is free and is what most documentation pipelines use. Chrome supports almost none of that, so a generated report with "Page 3 of 12" in the footer needs one of them rather than this.

Frequently asked questions

Will it look exactly like my page?

Yes — it comes out exactly as Print → Save as PDF produces. Flexbox, grid, floats, gradients, shadows, SVG and web typography come out exactly as they look on screen.

Is my HTML stored anywhere?

It is sent to our server over an encrypted connection, converted, and deleted the moment your PDF is made — nothing is stored, logged or shared. If that server is ever unreachable, the tool falls back to its own converter and tells you so.

Is JavaScript executed?

No, deliberately — the page is rendered from its markup and styles only. Running untrusted scripts server-side would be a security hole, and a document worth converting should not need to assemble itself at runtime.

Can I use external images or stylesheets?

No — the conversion is sealed off from the network for security. Inline your CSS and embed images as data URIs; everything self-contained renders perfectly.

Is the text selectable?

Yes. The PDF carries real vector text and graphics — not a screenshot — so it stays sharp at any zoom and can be selected, searched and copied.

How are page breaks decided?

By real print CSS: content flows across pages, and page-break-before, page-break-after and page-break-inside rules in your markup are honoured exactly as a browser honours them when printing.

Good to know: Scripts are not executed and the conversion has no network access — inline your styles and embed images as data URIs. Live URLs cannot be fetched; save the page as a file first. If our server is unreachable, the browser fallback keeps text and simple layout but simplifies advanced CSS.