← All posts

JPG vs PNG: which one should you use?

JPG vs PNG: which one should you use?

If you have ever saved a picture and wondered whether it should be a JPG or a PNG, the short answer is this: use JPG for photos and PNG for anything with sharp edges, text or a transparent background. The details below will help you decide when a picture sits somewhere in between.

JPG, for photos

JPG makes files smaller by throwing away detail that your eye rarely notices. At a good quality setting the result looks almost the same as the original, and the file is a fraction of the size. This is why most cameras and phones save JPG by default.

The trade-off shows up when you push it too far. Low quality leaves blocky patches around text and hard edges, and every re-save adds a little more loss. Keep an untouched copy of the original.

PNG, for sharp graphics

PNG keeps every pixel exactly as it was. Nothing is discarded, so text, lines and logos stay crisp however many times you open and save the file. It also supports transparent backgrounds, which is why most logos and cut-outs on the web are PNGs.

The cost is size. The same photo saved as PNG can be many times bigger than the JPG, so PNG is a poor choice for large pictures on a website.

PNG vs JPG side by side

Photo by Albert Hyseni on Unsplash

JPGPNG
CompressionLossy: some detail is removedLossless: nothing is removed
TransparencyNoYes
File size, 1080px photoAbout 80 to 170 KB at quality 80About 0.8 to 1.4 MB
Quality after re-savingDrops each timeStays the same
Text and sharp edgesCan look blurry or blockyStays crisp
Best forPhotos, email, websitesLogos, screenshots, cut-outs

Which one should you pick?

For file transfers, like mailing, or using it in wesbites, use JPEG. Generally a quality of 80 is best, which gives better quality-compression tradeoff.

For a logo, or a screenshot with text, or a diagram or images with transperant brackground, use PNG.

WebP handles both cases in one format, with smaller files than either. Some older devices(ones before 2010) still cannot open WebP images, so check the compatibility.

Need to change format, locally and privately? The image converter works in your browser, so your files stay on your device.