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

Compare transparency, image quality, compatibility and file size using real exports of the same graphic.

Choose for the place you’ll use the image

For a logo that must blend into a page, start with PNG. For a photo to email or upload, start with JPG if the destination accepts it. If you control a website, test WebP or AVIF against the same image at the size visitors will see, and offer a fallback where needed.

What each format can hold
FormatTransparencyEncodingCommon choice
PNGYesLosslessLogos, screenshots, diagrams and sharp text.
JPG (JPEG)NoLossyPhotos shared with apps or upload forms that expect JPEG.
WebPYesLossy or lossless. FormatHopper’s quality control uses lossy encoding.Website images when the browser and publishing workflow accept WebP.
AVIFYesLossy or lossless. FormatHopper’s AVIF tools read supported still inputs.Website images when the destination can open AVIF and you have a fallback.

One graphic, three exports

This original 240 × 160 graphic has transparent corners and fine alternating colors in the center. Download the source PNG. In PNG to JPG, choose 25% quality and a white background. Open that result in JPG to PNG. Separately, export the source PNG as WebP at 75% quality.

Blue-framed card with a fine orange and teal stripe pattern and a transparent margin shown over checks.
Source PNG · 847 bytes
The card on white, with the fine stripes reduced to a plain-looking gray area.
JPG at 25% · 1,382 bytes
The JPEG exported as PNG still has a white margin and the plain-looking center.
JPG exported as PNG · 6,365 bytes
The WebP has a transparent margin. The colors of the fine pattern merge in the center.
WebP at 75% · 1,356 bytes

The 25% JPG turned two neighboring orange and teal source pixels into the same gray. Converting that JPG to PNG kept those decoded gray pixels and the opaque white corners. A lossless export keeps what it receives. Once the JPG has discarded detail, the original file is the way to recover it.

The small, flat-color PNG was the smallest in this run. These are measurements from one browser and one graphic. Photos, dimensions, quality settings and browser encoders can produce different results. With Image Compress, compare the actual byte counts and look at edges, gradients and faces before replacing a copy.

Check both reading and writing support

A browser may read AVIF but lack the WebP encoder that a conversion needs. The photo editor, phone or upload form receiving your output also needs to read it. Try the synthetic AVIF version of the card in AVIF to PNG. In the tested browser it produced a 240 × 160 PNG with transparent corners. If your browser cannot decode the AVIF, open it in an AVIF-capable app first. If it can decode it but cannot write WebP, use PNG for transparency or JPG for an opaque copy.

Transparency and lossless encoding tell you only part of what an export preserves. Canvas conversion can change color through decoding and omit original profiles, HDR information, camera metadata and other embedded data. Keep the original for color-critical work, and compare the copy in the app where it will be used.