How to convert a PDF to HTML (and get a real web page)

Turn a PDF into a web page with HTML, CSS and images: keep the exact look of every page, or get a clean, phone-friendly page. Free, in your browser.

Compress & convertBy the EddiesPDF teamUpdated 4 min read
Open PDF to HTML

A PDF is great for printing and sharing a fixed document, but it isn't a web page. Search engines read it less well, it's awkward on a phone, and you can't drop it into a website and style it like the rest of your pages. Converting it to HTML fixes that: you get a page that opens in any browser, with text that can be selected, searched, translated and indexed.

PDF to HTML does the conversion in your browser. The PDF isn't uploaded, and once the page has loaded the tool also works offline.

Two kinds of web page

There isn't one right way to turn a PDF into HTML, because a PDF and a web page work differently. A PDF fixes every letter at an exact spot on a page of a set size. A web page flows: the text wraps to fit the window, and the same page has to work on a phone and a wide screen. So the tool gives you a choice.

Looks the same

Every page keeps its size, layout, pictures and colors. The page's graphics (photos, lines, boxes, backgrounds) become one image, and the text sits on top of it as real HTML text in the same place, size and color. You can still select and copy it, and search engines and screen readers can read it.

The pages scale down to fit a phone screen and keep their proportions, using CSS only, so there's no JavaScript in the result. Pick this for brochures, flyers, forms, certificates, menus and anything where the design is the point.

Clean web page

The content is rebuilt as a normal web page in reading order. Columns are put in order, lines are joined into paragraphs, large text becomes h1, h2 and h3 headings, bulleted and numbered items become lists, tables become HTML tables, and pictures are cut out and saved as images. The stylesheet uses the document's main font and text size, keeps colored text, and is easy to change.

Pick this for articles, reports, manuals and anything you want to edit, publish as a blog post or read comfortably on a phone.

Step by step

1. Open PDF to HTML and drop your PDF on the page, or click Upload PDF file. A password-protected PDF asks for its password, which stays in your browser. 2. Choose the Layout: Looks the same or Clean web page. 3. To convert only part of the file, type a range in Pages, such as 1-3 or 2, 5-7. Leave it empty for the whole document. 4. Under More options, pick how you want the download: - Separate files (ZIP): index.html, style.css and an images folder. Best for editing and uploading to a website. - One .html file: the styles and images are built into a single file. Best for emailing or opening on a phone. 5. With Clean web page you can also untick Include pictures for a text-only page, or tick Mark page breaks to add a thin line where each PDF page started. 6. Click Convert to HTML. A live preview of the page appears, so you can scroll through it before you download. 7. Click Continue to download, then Download.

What's in the ZIP

  • index.html: the page itself. Open it in any browser by double-clicking it.
  • style.css: all the styling. The HTML links to it, so keep the two files together.
  • images/: the page backgrounds (Looks the same) or the pictures (Clean web page). Pages with nothing behind the text get no image at all, which keeps the download small.

To put the page on a website, upload the three items to the same folder and link to index.html. You can rename index.html, as long as style.css and the images folder stay next to it.

Getting the best result

Fonts. The HTML uses the font names from the PDF, with common fallbacks such as Arial or Times New Roman. If the PDF used a font the viewer doesn't have, a similar one is shown. In Looks the same, each piece of text is stretched or narrowed slightly so it still covers the same width as in the PDF, which keeps lines from overlapping.

Scanned PDFs. A scan is a picture of a page, with no text inside. Looks the same still gives you a web page showing the scan, but nothing can be selected or found by search engines. Run OCR PDF first, then convert the result to get real text.

Complex layouts. Magazine pages with text flowing around pictures, or pages with many small boxes, can come out in an odd order in Clean web page. Looks the same handles them well, because nothing is moved.

Things that aren't converted. Form fields, links, comments and attachments aren't carried over. If you need a fillable form on a website, build it in HTML after converting. If you need the PDF to keep working as a PDF, keep the original too.

Going the other way

To turn a web page into a PDF, use HTML to PDF. If you only need a PDF's fonts, sizes and colors as a stylesheet, for example to make a website match a printed brochure, PDF to CSS writes them as a ready-to-use CSS file.

Try PDF to HTML
Free, no sign-up, and it works on your phone too.
Open PDF to HTML

Also useful: PDF to CSS · HTML to PDF · OCR PDF

More guides