You take a screenshot, export a design, download a photo — and suddenly you're staring at a Save As dialog with six format options. JPEG? PNG? WebP? Your gut says "just pick JPEG" and move on. But that instinct is costing you megabytes, loading time, and in some cases — transparency that you needed.

This guide cuts through the noise. We'll cover every major image format used on the web today, explain exactly what each one is good at, and give you a simple decision rule you can actually remember.

Why Your Image Format Choice Matters More Than You Think

A 2MB PNG and a 200KB JPEG can look identical on screen. But that 1.8MB difference affects:

  • Page load speed — images are typically the largest assets on a web page
  • Core Web Vitals — Google's LCP (Largest Contentful Paint) is directly impacted by image load time
  • Mobile data usage — on slow connections, large images abandon visitors before they load
  • Storage costs — CDN bandwidth and storage fees scale with file size
  • SEO — Google uses page speed as a ranking signal

Choosing the right format from the start isn't a minor optimization — it's one of the highest-impact decisions you make when building for the web.

JPEG — The Reliable Old Standard

Introduced in 1992, JPEG (Joint Photographic Experts Group) is the most widely supported image format in existence. It's on every camera, every operating system, every email client, and every web browser that has ever existed.

How it works: JPEG uses lossy compression. It divides the image into 8×8 pixel blocks and discards color information that the human eye is least sensitive to — subtle variations in hue and saturation in dark areas, for example. The quality slider controls how aggressively this information is thrown away.

JPEG

Lossy compression — best for photographs and images with gradients.

  • ✅ Universal support — literally everywhere
  • ✅ Excellent for photos
  • ✅ Small file sizes at medium quality
  • ❌ No transparency support
  • ❌ Artifacts at low quality
  • ❌ Each re-save degrades quality

When to use JPEG: Photographs, social media posts, hero images, product photos, any image where you don't need transparency and visual perfection isn't critical. Quality 75–85 is the sweet spot for web use — around 60–80% smaller than the same image at maximum quality with very little visible difference.

When NOT to use JPEG: Screenshots, logos, icons, text-heavy images, or anything with a transparent background. JPEG renders sharp edges as blurry halos (ringing artifacts) and can't store alpha transparency at all.

PNG — Lossless Clarity for Everything Else

PNG (Portable Network Graphics) was created in 1996 as a patent-free alternative to GIF. Unlike JPEG, PNG uses lossless compression — every pixel is stored exactly as it appears. The result is perfect image quality at the cost of larger file sizes.

PNG

Lossless — stores every pixel exactly. Essential when transparency is needed.

  • ✅ Full transparency (alpha channel)
  • ✅ Lossless — no quality degradation
  • ✅ Perfect for screenshots and text
  • ✅ Re-save indefinitely without loss
  • ❌ Large files for photos
  • ❌ No animation (except APNG)

When to use PNG: Logos, icons, screenshots, UI elements, any image with transparency, images containing text, diagrams, and illustrations with flat colors. Also use PNG as your archival master — save originals as PNG, then export compressed versions for delivery.

When NOT to use PNG: Photographs on web pages where file size matters. A landscape photo as PNG might be 3–8MB; the same image as JPEG at quality 80 might be 200–400KB. For photos, JPEG or WebP will always win on file size.

PNG-8 vs PNG-24

PNG-8 stores up to 256 colors and was once used for simple graphics. PNG-24 stores full 16 million colors plus alpha transparency. Most modern tools export PNG-24 by default. For simple flat-color graphics, PNG-8 (or SVG) can be dramatically smaller.

WebP — The Web's Best All-Rounder

WebP was developed by Google and released in 2010, but it only became truly mainstream around 2020 when Safari added support. In 2025, browser support sits at 97%+ worldwide — making WebP the safe default for nearly all web projects.

How it works: WebP supports both lossy and lossless compression, transparency, and animation. Its lossy mode uses the same prediction/transform coding as the VP8 video codec, which is why it consistently outperforms JPEG.

WebP

Modern format with lossy and lossless modes. The best general-purpose web format.

  • ✅ 25–35% smaller than JPEG
  • ✅ Transparency support
  • ✅ Animation support
  • ✅ 97%+ browser support (2025)
  • ❌ Limited email client support
  • ❌ Not all social platforms preserve it

Typical size savings: A 1MB JPEG photo converted to WebP at equivalent visual quality typically produces a 650–750KB file — a 25–35% reduction. For PNG-to-WebP, savings are even more dramatic for photographic content.

When to use WebP: Images on your website, web app, blog posts, thumbnails, hero images, product photos — any image that will be viewed in a browser. WebP is now the correct default for web delivery.

When to keep JPEG/PNG: When sharing via email, messaging apps (WhatsApp, iMessage), or platforms that might re-encode your image anyway (Instagram, Twitter). Always keep a JPEG or PNG copy for maximum compatibility.

Serving WebP with a fallback

Use the HTML <picture> element to serve WebP with a JPEG fallback: <picture><source srcset="image.webp" type="image/webp"><img src="image.jpg" alt="..."></picture>. Modern browsers use WebP; browsers that don't support it fall back to JPEG automatically.

AVIF — The Future Format (With Caveats)

AVIF (AV1 Image File Format) is based on the AV1 video codec developed by the Alliance for Open Media. It achieves significantly better compression than both JPEG and WebP — often 40–50% smaller than JPEG at the same quality.

AVIF

Next-generation format with superior compression. Growing support in 2025.

  • ✅ 40–50% smaller than JPEG
  • ✅ Better than WebP at same quality
  • ✅ Transparency and HDR support
  • ⚠️ Encoding is slow on CPU
  • ⚠️ Missing from some edge cases
  • ❌ Not supported in older Safari

Browser support in 2025: Chrome 85+, Firefox 93+, Safari 16+, Edge 121+. That covers ~88% of users globally. The gap vs WebP's 97% is shrinking, but still meaningful if your audience includes older devices or Safari on older iOS.

When to use AVIF: When you've verified your audience's browser support or can serve with a WebP/JPEG fallback via <picture>. Image-heavy sites (news, e-commerce, photography) see the biggest benefit from AVIF's compression.

GIF, SVG, and BMP — When Do These Fit?

GIF — Animation Only

GIF is 37 years old and supports only 256 colors — terrible for photos, barely adequate for simple graphics. Its only remaining legitimate use is animated images, and even that is being replaced by WebP animations and short video (MP4/WebM). For static images, never use GIF. For simple animations, prefer WebP animated or a short video clip.

SVG — The Scalable Choice for Graphics

SVG (Scalable Vector Graphics) is not a raster format — it stores shapes, paths, and text as mathematical instructions, not pixels. SVGs scale to any resolution without quality loss, making them perfect for logos, icons, illustrations, and any graphic that needs to look sharp on retina/4K displays. File sizes can be remarkably small. If your image is a vector graphic rather than a photograph, SVG is almost always the right choice.

BMP — Never for Web

BMP (Bitmap) stores raw pixel data with no compression. A 1920×1080 BMP is around 6MB. There is no reason to use BMP for web delivery. It exists as an intermediate format in some Windows workflows. Always convert BMP to JPEG, PNG, or WebP before publishing.

Convert Images Between Formats Instantly
Batch convert JPEG, PNG, WebP, GIF, and BMP — set quality, handle transparency, and download as ZIP. All in your browser, no upload.
Open Image Converter

Full Format Comparison Table

FormatCompressionTransparencyAnimationBrowser SupportBest File SizeEmail Safe
JPEGLossyNoneNo100%PhotosYes
PNGLosslessFull alphaAPNG100%Graphics/UIYes
WebPLossy + LosslessFull alphaYes97%Photos + GraphicsLimited
AVIFLossy + LosslessFull alphaYes88%EverythingNo
GIFLossless (256 col)BinaryYes100%Simple animationsYes
SVGVectorYesCSS/JS99%Icons/logosLimited
BMPNoneOptionalNoMostNeverNo

The Simple Decision Rule

Format Cheat Sheet — 2025

Photo→ WebP (or JPEG as fallback). Quality 75–85.
Logo→ SVG if vector. PNG if raster. WebP is fine too.
Screenshot→ PNG (lossless, preserves text sharpness). Or WebP lossless.
Icon→ SVG (scalable). PNG as fallback for ICO formats.
Transparent→ PNG or WebP. Never JPEG.
Animation→ Short: MP4/WebM video. Simple: WebP animated. Avoid GIF.
Email→ JPEG or PNG. WebP may show as broken in Outlook.
Social→ JPEG (platforms re-encode anyway). 1200×630px for shares.
Archive→ PNG or TIFF. Never save master files as JPEG repeatedly.

Image Formats and SEO — What Actually Matters

Google's documentation is clear: page speed is a ranking signal, and images are usually the biggest drag on page load. The format decision directly affects your Core Web Vitals scores.

What Google recommends:

  • Serve images in "next-gen formats" — specifically WebP and AVIF are mentioned in Lighthouse audits
  • Compress images appropriately for their display size
  • Use lazy loading for images below the fold
  • Specify width and height attributes to prevent layout shift (CLS)
  • Use descriptive alt text for accessibility and image search

A practical improvement order: (1) Switch photos from PNG to JPEG or WebP first — this has the largest single impact. (2) Reduce quality to 75–80 for photos. (3) Serve WebP with JPEG fallback. (4) Implement lazy loading. (5) Use AVIF where you can verify support.

Don't convert and re-convert

Every time you save a JPEG as a JPEG, you lose quality. Each generation of lossy compression adds more artifacts. Always keep your original in PNG or a RAW format and only export compressed versions as the final step. Never compress a compressed image unless you accept the quality loss.

A Note on Transparency That Trips People Up

Transparency in images is stored as an alpha channel — a fourth value alongside R, G, and B that says "how opaque is this pixel?" A value of 0 is fully transparent (invisible). A value of 255 is fully opaque.

JPEG has no alpha channel. When you convert a PNG with transparency to JPEG, the transparent areas need to be filled with something. Most tools fill with white. This is why transparent logos on dark backgrounds look broken when saved as JPEG — the "transparent" area becomes a white box.

WebP and PNG both support full alpha transparency. For images that need to float over backgrounds (logos, product cutouts, circle-cropped avatars), always use PNG or WebP.