Skip to content
🌐

HTML to PDF

Convert any web URL into a clean PDF.

✓ Free 🔒 Secure ⚡ Fast 📁 Up to 25MB
Server processed Processed on our servers over HTTPS, then deleted within 1 hour. Files are processed automatically. No human reviews your documents, and PDFRun does not use them to train models.
Drop your file here

or click to browse — supports PDF files up to 25MB

✓ HTML to PDF — done

Processed successfully. Download below.

How to use

  1. 1 Drop or click to upload your file
  2. 2 Adjust options if shown
  3. 3 Click HTML to PDF
  4. 4 Download your result instantly
🚀 Go Pro
  • Files up to 1 GB
  • Unlimited jobs/hour
  • Batch processing (up to 100 files)
  • Priority support
Upgrade to Pro
🔒 Privacy

Files are processed securely and deleted within 1 hour. Files are processed automatically. No human reviews your documents, and PDFRun does not use them to train models.

Related Tools

Why this works

Convert an HTML file (.html or .htm) into a PDF — useful for archiving web pages you’ve saved locally, generating reports from HTML templates, or sharing styled content as a fixed document.

HTML and PDF serve adjacent jobs: HTML is for live, interactive content that adapts to the viewer’s device; PDF is for fixed, paginated content that looks the same to every recipient. Converting HTML to PDF is the right call when: you’ve saved a web page locally and want it as a permanent record; you’ve generated an HTML report (from a script, a templating tool, or a dashboard export) and need to share it as a single file; you need to print HTML content with reliable pagination that the browser’s print dialog won’t give you cleanly.

Drop in your .html or .htm file. Linked resources — CSS, images, fonts — are loaded if they’re embedded inline (via `<style>` tags, data URLs, base64 image attributes) or referenced by absolute URLs to publicly accessible sources. Resources referenced by relative paths to other local files won’t resolve, because we can’t see your local filesystem. For an HTML page with linked CSS or images, save the page as “HTML, Complete” in your browser (which embeds resources) or use “Save as MHTML” and convert that instead.

Layout: the converter renders your HTML as a browser would, paginated at standard letter or A4 page size. Pages break at sensible content boundaries where possible — we won’t split a single paragraph across pages, and tables generally stay intact. CSS `@media print` rules are honoured, so any print-specific styling in your HTML (hiding navigation, expanding link URLs, adjusting font sizes) takes effect in the PDF.

What doesn’t convert: interactive content (forms, hovers, JavaScript-driven animations), embedded video and audio (a static frame is used if available), real-time data fetched by JS at page load. The output is a snapshot of what your HTML renders to at conversion time.

For producing PDFs from web pages programmatically (e.g. generating invoices from an HTML template), the typical pattern is: render the HTML server-side with your template values, save to a temp file, run through HTML to PDF, deliver to the user. Our API (in development) will support this flow natively without the temp file.

How it works

  1. 1
    Upload your HTML file
    Drop your .html or .htm file into the upload box. Embedded CSS and images convert cleanly; externally-linked relative paths won’t resolve.
  2. 2
    Save complete pages for best results
    If your HTML uses linked stylesheets or images, save the page as “HTML, Complete” (or MHTML) in your browser so resources are embedded inline.
  3. 3
    Run the conversion
    Press Convert. Most pages convert in 3–6 seconds; complex pages with many images take a few seconds longer.
  4. 4
    Download the PDF
    You’ll get a paginated PDF that looks like your HTML did in print preview, with sensible page breaks and embedded fonts.

Real-world uses

Developers

Generate styled PDF reports from HTML templates with company branding, charts, and tables.

Bloggers

Archive a published post as a PDF for offline reading or sharing.

Researchers

Save documentation pages or scraped web content as permanent PDF records.

Marketing teams

Convert an HTML newsletter into a PDF for legal/compliance archival.

Common questions

Will CSS styling be preserved?

Yes — CSS embedded via `<style>` tags or linked from absolute URLs renders in the PDF. CSS `@media print` rules are honoured, so print-specific styling (hidden navigation, expanded link URLs) applies to the output.

What about images and fonts?

Inline (data URL, base64) and absolute-URL resources load and render. Relative-path resources (linking to other local files) won’t resolve. For best results, save the source as “HTML, Complete” in your browser or save as MHTML — both embed resources.

Will JavaScript run?

JavaScript executes during rendering, but the PDF captures a single snapshot — interactive behaviours (hovers, click handlers, animations) don’t survive into the PDF. Data fetched by JS at load time does appear in the PDF as static content.

Can I convert a webpage from a URL?

Not directly in this tool — we accept HTML files, not URLs. Workflow: save the webpage to a local HTML file (browser → File → Save Page As → HTML, Complete), then upload that. The forthcoming PDFRun API will accept URLs directly.

Will my output have page numbers?

Not by default — the output reflects your HTML’s own pagination behaviour. To add page numbers, run the output through the Page Numbers tool, or add CSS `@page` rules with `@bottom-center { content: counter(page) }` to your source HTML.

What page size does it use?

Letter (US) by default, with the page size detectable from any CSS `@page` rule in your source. For A4 output, add `@page { size: A4 }` to your stylesheet before converting.

Related tools & guides