PNG vs JPG for PDF Pages: When Lossless Wins, When JPG Is Enough
The most common question when converting PDF pages to images is "PNG or JPG?" The two formats compress in fundamentally different ways, so the right answer swings drastically depending on what's actually on the page. This article breaks the decision down into four criteria and shows which format wins for each case.
How they compress, really
PNG is lossless. Not a single pixel is dropped. That makes it brilliant at compressing repeating colors (text, solid backgrounds, line art) and bad at compressing photographic content where every pixel differs from the next.
JPG is lossy. It throws away detail the eye is unlikely to notice. That works wonders for gradual color transitions (photos) but produces tell-tale "ringing" halos around sharp edges of text and shapes.
Four criteria for the decision
Measured file sizes (A4, 150 DPI)
Same source PDF, same resolution, real-world averages:
| Content | PNG | JPG (q=80) | Pick |
|---|---|---|---|
| Text-heavy report | 200 KB | 350 KB | PNG |
| Charts & slides | 400 KB | 500 KB | PNG |
| Mixed text + photo | 1.5 MB | 300 KB | It depends |
| Photo spread | 3.5 MB | 450 KB | JPG |
Counter-intuitively, PNG actually wins on text pages — large solid-color regions compress so well that JPG can't catch up.
One more: what about WebP?
WebP combines the best of both — about 25% smaller than PNG and 30% smaller than JPG at matched quality, and it supports lossless, lossy, and alpha. The catch: not many PDF tools target WebP directly, and some older environments (pre-2019 Office, etc.) refuse to open it. WebP for modern web, PNG/JPG when compatibility matters is the realistic rule of thumb.
Bottom line
One sentence: text, line art, and logos → PNG; photo-heavy pages → JPG. For mixed PDFs default to PNG and convert problem pages to JPG individually. Our web converter outputs PNG only — if size becomes a concern for photo-heavy decks, re-encode to JPG with ImageMagick afterward.