Choosing an image format used to be simple: use JPEG for photos, PNG for graphics with transparency. Today you have three serious options for the web, and the difference in file size between the worst and best choice can be 50% or more — for the same visual quality.
This guide gives you real compression numbers, a plain-English explanation of each format, and a decision table you can bookmark.
Convert JPG to WebP — batch, no uploads →
The quick answer
| Use case | Recommended format |
|---|---|
| General web photos | WebP |
| Maximum compression, modern browsers | AVIF |
| Email attachments | JPEG |
| Compatibility with any software | JPEG |
| Transparency (logos, UI elements) | WebP or PNG |
| Images you'll edit again | Keep as JPEG or PNG — don't re-encode |
| E-commerce product shots | AVIF (with WebP fallback) |
If you're not sure, WebP is the right default for the web today.
JPEG: still the safe default
JPEG has been the dominant photo format for 30 years, and for good reason: it works everywhere. Every browser, every image editor, every email client, every device camera (until iPhones switched to HEIC) shoots or displays JPEGs without any special support.
The JPEG compression algorithm works by dividing an image into 8×8 pixel blocks and discarding frequency information the human eye is less sensitive to. At quality 85, most people genuinely cannot distinguish a JPEG from the original. At quality 70–75, you start to see blocking artifacts on fine detail like hair, text edges, and sky gradients.
File size benchmark (20-megapixel iPhone photo, same visual quality):
- JPEG quality 85: ~750 KB
When JPEG is still the right choice:
- Sending to someone who might use Photoshop 2010, a legacy CMS, or any non-web context
- Email attachments — attachment previews work universally with JPEG
- Images destined for print (print workflows expect JPEG or TIFF)
- As your archive master file — JPEG is stable, not going anywhere, and editable by anything
WebP: the browser-safe modern choice
WebP was developed by Google and first shipped in Chrome in 2010. It uses a more sophisticated compression algorithm than JPEG — specifically, it borrows techniques from the VP8 video codec. The result is a meaningfully smaller file at the same perceived quality.
File size benchmark (same source photo):
- WebP quality 80: ~520 KB — roughly 31% smaller than JPEG
Browser support reached "basically universal" when Safari added WebP support in version 14 (September 2020). Today, WebP works in Chrome, Firefox, Edge, Safari, and all mobile browsers — covering over 97% of global web traffic.
WebP also supports:
- Transparency (alpha channel) — both lossy and lossless modes
- Lossless mode — pixel-perfect quality, typically 25% smaller than equivalent PNG
- Animation — smaller than animated GIF
When to use WebP:
- Default choice for any photo or image on a modern website
- Product images, blog photos, hero images
- Anywhere you'd have used JPEG and don't need IE11 support
- Logos and UI elements that need transparency (as a PNG replacement)
Converting JPG to WebP: Use ConvertYard's JPG to WebP converter — batch up to 1000 files, no uploads, quality and resize controls included. The default quality of 80 is the standard for web delivery.
AVIF: the best compression available
AVIF (AV1 Image File Format) is the newest of the three and produces the smallest files. It uses the AV1 video codec — developed by the Alliance for Open Media — applied to still images. The compression efficiency is substantially better than both JPEG and WebP.
File size benchmark (same source photo):
- AVIF quality 70: ~370 KB — roughly 51% smaller than JPEG, 29% smaller than WebP
The trade-offs are real:
- Encoding speed: AVIF encoding is 2–20x slower than WebP at equivalent quality settings. For a batch of 100 photos, this is noticeable.
- Browser support: ~93% globally. The gap is older Safari and iOS versions (pre-16.4, released March 2023). Safari 15 and earlier cannot display AVIF.
When to use AVIF:
- Image-heavy e-commerce sites where bandwidth directly affects load time and conversion rates
- News sites and blogs with many photos per article
- Any context where you control serving and can use a
pictureelement with WebP fallback
Serving AVIF with WebP fallback:
<picture>
<source srcset="photo.avif" type="image/avif" />
<source srcset="photo.webp" type="image/webp" />
<img src="photo.jpg" alt="Description" />
</picture>
This delivers AVIF to browsers that support it, WebP to the rest, and JPEG to anything older.
Converting JPG to AVIF: Use ConvertYard's JPG to AVIF converter. Expect longer encoding times than WebP — AVIF earns its size savings through computation.
Real compression data
These numbers come from converting the same 20-megapixel iPhone 15 Pro photo — a typical outdoor scene with sky, foliage, and a person.
| Format | Quality setting | File size | vs JPEG |
|---|---|---|---|
| JPEG | 85 | 748 KB | baseline |
| JPEG | 75 | 512 KB | −32% |
| WebP | 85 | 590 KB | −21% |
| WebP | 80 | 520 KB | −31% |
| WebP | 70 | 390 KB | −48% |
| AVIF | 80 | 430 KB | −43% |
| AVIF | 70 | 370 KB | −51% |
| AVIF | 60 | 280 KB | −63% |
Key insight: switching formats saves more than increasing compression. Going from JPEG 85 to WebP 80 saves 31% while maintaining equivalent visual quality. Going from JPEG 85 to JPEG 70 saves 32% but introduces visible artifacts at fine-detail edges.
These percentages vary by image content. Images with smooth gradients (sky, skin) compress dramatically better in modern formats. Images with fine texture (fabric, grass, fur) see smaller gains.
Which format for your specific use case
You run an e-commerce site: Use AVIF for all product images with a WebP fallback. The 50% size reduction directly improves page load time and Core Web Vitals scores, which affect both SEO and conversion rates. Use ConvertYard's batch converter to process your catalog.
You're a blogger or content site: WebP is the practical choice. Universal browser support, 30% file size savings, and no meaningful encoding overhead. Convert your image library to WebP and you're done.
You're building a portfolio: WebP for photos, PNG for any graphics where pixel-perfect edges matter (UI screenshots, diagrams, logos with transparency).
You're a photographer sharing proofs with clients: JPEG. Clients may open images in Lightroom, older Photoshop, or any number of legacy tools. JPEG works everywhere.
You need to compress an existing library: Format conversion is the biggest lever. If you have JPEGs from 2015, converting them to WebP typically saves 25–35% with no visible quality loss. Use ConvertYard's image compressor for mixed-format batches.