JPG vs PNG vs WebP vs AVIF: which image format should you use?

A plain comparison of JPG, PNG, WebP, AVIF, GIF and HEIC: file size, quality, transparency and support, with a simple rule for which to pick.

Convert imageTurn any image into JPG, PNG, WebP, AVIF, GIF, BMP or ICO. Free, no upload.
Convert image on AllFreeImage with a photo open
Convert image on AllFreeImage

The short answer

Photos for the web: WebP, or AVIF where supported. Photos to share or print: JPG. Logos, screenshots and anything with text or transparency: PNG, or SVG for logos. Short animations: a video file if you can, GIF if you must.

JPG

JPG has been the default photo format since the 1990s and opens everywhere. It uses lossy compression: it throws away detail the eye is unlikely to miss. At 80 to 90 percent quality the loss is invisible for photos, but sharp text and flat color show smudgy artefacts. It has no transparency.

PNG

PNG is lossless: every pixel is stored exactly, and it supports transparency. That makes it right for logos, icons, diagrams and screenshots, and wrong for photos, where the files become huge. Reducing a PNG to 256 colors or fewer, as Compress image can, often cuts the size by 60 to 80 percent with little visible change for graphics.

WebP and AVIF

WebP, from Google, does both lossy and lossless compression and supports transparency. Lossy WebP photos are typically 25 to 35 percent smaller than JPG at the same visual quality, and every current browser supports it.

AVIF is newer and smaller again, often half the size of JPG, and keeps detail better at low quality. All current browsers can display it, but fewer apps can open it and saving it is slower.

GIF and HEIC

GIF is limited to 256 colors per frame and is only worth using for simple animations where nothing else is accepted. HEIC is what iPhones save; it is efficient but poorly supported outside Apple devices, so convert it to JPG before sharing.

To switch between any of these, use Convert image, which saves to JPG, PNG, WebP, AVIF, GIF, BMP or ICO.

The same photos in every format

We saved six photos at 1600 pixels wide. These are the averages. AVIF and WebP quality numbers are not the same scale as JPG, so treat the list as a guide to the order, not an exact contest. What it does show clearly is the cost of using PNG for a photo.

For a screenshot with flat areas and small text the order changes. There a PNG reduced to 256 colors can be smaller than a JPG and has no smudges around the letters.

FormatAverage sizeTransparencyOpens in
JPG 80%182 KBNoEverything
WebP 80%111 KBYesAll browsers, most newer programs
AVIF 80%73 KBYesAll browsers, some programs
PNG3,166 KBYesEverything
PNG, 256 colors626 KBYesEverything
Average of six photos, 1600 pixels on the long side, saved with the AllFreeImage encoder in December 2026.

Which one to keep as your master copy

Keep the original: the HEIC or JPG from the phone, the RAW file from the camera, or the project file from the design program. Make JPG, WebP and AVIF copies from it whenever you need them. Editing a copy, saving it, and editing that copy again is how photos slowly turn muddy.

A rule you can remember

Is it a photo? JPG to send, WebP to publish. Does it contain text, a logo or see-through parts? PNG. Can it be drawn with shapes? SVG. Does it move? Video. That covers almost everything, and the rest is fine-tuning.