pdfblah.com

← All guides

How to convert a PDF to images (PNG or JPG)

Turn each page of a PDF into a sharp PNG or JPG at whatever resolution you need, for a thumbnail, a slide, or an email. Or pull the original images back out of the file. Here is how.

Two different jobs

"PDF to image" can mean two things, and pdfblah does both:

Render pages to images online

  1. Open the editor and drop in your PDF.
  2. Pick PNG in the Output panel.
  3. Download. One page comes back as a PNG, several as a zip.

For JPG, a specific resolution, or pulling out embedded images, use the command line or the free local app:

Three ways to do it

Same engine, same result. Pick one:

pip install pdfblah

# every page to PNG at 150 dpi
pdfblah render in.pdf -o images/ --dpi 150 --format png

# just page 1 as a high-res JPG (a thumbnail or cover)
pdfblah render in.pdf -o images/ --pages 1 --dpi 300 --format jpg

# pull out the images already embedded in the PDF
pdfblah extract in.pdf --images -o extracted/

The app and CLI are open source (MIT). See the pdfblah project on GitHub.