HTML to PDF Converter (Text and Structure)
Turn the text of an HTML file or snippet into a simple PDF. Your HTML stays on your device.
- Runs in your browser
- No sign-up
- No watermark
This tool reads the structure of an HTML document and writes it to a PDF: headings, paragraphs, bold and italic text, links, ordered and unordered lists, quotes, code blocks, horizontal rules and simple tables. It is meant for notes, articles, email bodies and generated reports where the content matters more than the look.
It is not a web page renderer. CSS, colours, images, web fonts and page layout are not reproduced, and scripts are not run or loaded. If you need a page to look exactly like it does on screen, open it in your browser and use Print, then Save as PDF. Your HTML is parsed locally in an inert document, so nothing is fetched and nothing leaves your device.
How to use HTML to PDF
- Choose an HTML file, or paste a full page or a snippet into the box.
- Pick the page size, margins, font and text size.
- Choose whether to show link addresses after the link text, and whether to add page numbers.
- Select Create PDF, then download the file.
Frequently asked questions
Does this reproduce my web page exactly?
No. A converter that runs only in your browser cannot render a page the way a browser does. This tool writes the text and structure to a PDF using one simple layout. CSS, colours, images, fonts and the page layout are not reproduced.
How do I get a pixel-exact PDF of a web page?
Open the page in your browser, choose Print, and pick Save as PDF as the destination. The browser then applies the real page styling. Turning on background graphics in the print dialog keeps colours.
Are scripts run or external files loaded?
No. The HTML is parsed into an inert document that is never shown on the page. Scripts do not run, and images, stylesheets and fonts are not downloaded. Script and style contents are ignored.
Which HTML elements are supported?
Headings h1 to h6, paragraphs, line breaks, bold, italic, links, ordered and unordered lists including nested ones, blockquotes, pre and code, horizontal rules and simple tables. Other elements are read as plain text. Elements with the hidden attribute or an inline display:none are skipped.
What happens to images?
Images are not placed in the PDF. If an image has alt text, the alt text is printed in its place as [Image: description].
How are tables handled?
Tables are drawn as a grid of bordered cells with wrapped text, and header rows repeat when a table runs onto another page. Cells that span several columns are shown in their first column, and a table inside a table is flattened to text.
Why do some characters show as question marks?
The PDF uses standard fonts that only cover Western European characters. Other alphabets, such as Cyrillic, Greek, Arabic, Hebrew or Chinese, and emoji are replaced with "?". The tool lists them after conversion.