PNG vs JPG: which one should you use?

Use JPG for photos and PNG for graphics: logos, icons, screenshots, diagrams and anything that needs a transparent background. JPG throws away detail you rarely notice in a photo and gets far smaller; PNG keeps every pixel exactly and keeps transparency, but photos saved as PNG are huge.

If you already have a PNG photo that is too big, converting it to JPG is usually the single biggest saving.

The short comparison

FeaturePNGJPG (JPEG)
CompressionLossless: decoded pixels match the original exactlyLossy: detail is discarded to save space
TransparencyYes, an optional alpha channel, so edges can fade smoothlyNo; one or three colour components, no alpha
Best forLogos, icons, screenshots, text, line artPhotos and scenes with smooth shading
Photo at 1600 × 1200 (our test)2,576,588 bytes142,405 bytes at quality 80%
Flat logo at 600 × 300 (our test)12,628 bytes (4,769 with 256 colours)10,635 bytes at quality 90%; 1.11% of pixels changed by more than 16 levels
Saving againNo loss, however many timesEach re-save at lossy quality can lose a little more

The two format facts in the table come from the specifications listed under Sources: the PNG specification describes “lossless” storage with “an optional alpha channel”, and the JPEG File Interchange Format allows “one or three components”, which leaves no room for an alpha channel. The byte counts are our own measurements, explained below.

Photos: JPG wins by a wide margin

A photo has millions of slightly different colours and fine noise. PNG has to record all of it exactly, so the file stays large. JPG keeps the overall picture and drops fine variation your eye barely sees, so the file shrinks a great deal.

That gap is typical in kind, though the exact ratio depends on the photo: busy, noisy pictures widen it, and very plain ones narrow it. For a photo you will share, email or upload, JPG is almost always the better choice. OurPNG to JPG converter does this in one step.

Graphics and text: PNG keeps edges clean

Logos, icons and screenshots have large areas of one flat colour and sharp edges. PNG compresses flat colour well and never blurs an edge. JPG approximates the picture instead of storing it exactly, and sharp edges between flat colours are the hardest part to approximate, so that is where its changes gather.

So for graphics, the better move is usually to keep PNG and cut its colours, not to switch to JPG.

Transparency decides it

If any part of the image needs to be see-through, such as a logo placed on coloured backgrounds or a product cut out of its photo, you need PNG (or WebP). Saving as JPG fills every clear pixel with a solid colour.

Converting between them

How we measured

Every byte count on this page comes from running this site’s own tools in Chromium on our sample images and saving the downloaded files. The photo is a synthetic test image made of gradients, soft shapes and grain rather than a camera picture, so your own photos will give different numbers, though the same pattern. Other browsers use their own JPG encoders and can produce slightly different sizes.

Questions

Does converting JPG to PNG improve quality?

No. The PNG stores exactly the pixels the JPG already had, including any blur or blockiness from JPG compression. In our test, a 42,125-byte JPG became a 237,968-byte PNG with no visible change.

Why did my PNG turn black or white behind the logo when I saved it as JPG?

JPG has no transparency, so clear pixels must be filled with a colour. Good converters let you choose it; ours uses white unless you pick another.

Which is better for a website?

Photos: JPG, or WebP where it is accepted. Logos, icons and screenshots: PNG, or SVG for simple vector logos. The best image format for the web guide goes through each case.

Sources

  1. Portable Network Graphics (PNG) Specification (Third Edition), W3C. Checked December 2026.
  2. JPEG File Interchange Format, version 1.02, hosted by W3C. Checked December 2026.

Browse all image guides