JPEG vs WebP vs AVIF: File Size Test
JPEG vs WebP vs AVIF tested on six photos at equal quality: AVIF was 62 percent smaller, WebP 32 percent. See our method, browser support and a calculator.

Last updated December 3, 2026
In our test of six photos at the same visual quality, WebP files were 32 percent smaller than JPEG. AVIF files were 62 percent smaller. JPEG was still the fastest to make and works everywhere.
We publish the full method below, so you can check it or repeat it. You will also see why a quality setting of 80 means different things in each format.
Key Takeaways
- At the same quality, AVIF was the smallest for all six photos we tested.
- WebP was always smaller than JPEG, by 25 to 46 percent.
- The same quality number is not the same quality across formats.
- AVIF took about twice as long as WebP to encode in our test.
- Use AVIF with a WebP or JPEG fallback for the best mix of size and support.
Digieh image format savings calculator
Digieh tool. Estimates use average savings from our own test on December 3, 2026. WebP was 32.0 percent and AVIF 61.6 percent smaller than JPEG at the same quality. Your photos may differ.
What Did the File Size Test Show?
Each format was set to the lowest quality that still scored 0.95 on structural similarity (SSIM). This common measure shows how close a copy looks to the original. So every file looks about the same.
| Photo | JPEG | WebP | AVIF |
|---|---|---|---|
| Laundry room | 101 KB | 74 KB (27 percent less) | 48 KB (52 percent less) |
| Restaurant table | 128 KB | 90 KB (30 percent less) | 50 KB (61 percent less) |
| Workbench | 77 KB | 58 KB (25 percent less) | 32 KB (58 percent less) |
| Office desk | 53 KB | 29 KB (46 percent less) | 17 KB (68 percent less) |
| Shop labels | 89 KB | 49 KB (45 percent less) | 24 KB (74 percent less) |
| Sneakers | 87 KB | 64 KB (26 percent less) | 35 KB (60 percent less) |
| Total | 534 KB | 363 KB (32 percent less) | 205 KB (62 percent less) |
Source: Digieh test, December 3, 2026, with Pillow 12.3.0, libwebp 1.6.0 and libavif 1.4.2. Six 1438 by 810 photos, matched at a similarity score of 0.95.
The office desk and shop label photos saved the most. Both have large smooth areas, which newer formats handle well.
How Did We Run the Test?
- We took six photos from our own articles, saved without any loss as PNG files.
- Each photo was 1438 by 810 pixels.
- For each format, we found the lowest quality with a similarity score of 0.95 or higher.
- We saved the size of that file and timed how long it took to make.
- We also saved each format at quality 80, a common default.
JPEG used progressive mode with optimized tables. WebP used its slowest, best setting, method 6. AVIF used the default speed in Pillow.
from PIL import Image
img = Image.open("photo.png").convert("RGB")
img.save("photo.jpg", "JPEG", quality=65, optimize=True, progressive=True)
img.save("photo.webp", "WEBP", quality=78, method=6)
img.save("photo.avif", "AVIF", quality=45)The quality numbers in this code are examples from one photo. The right number changes from photo to photo.
Why Is AVIF Bigger at Quality 80?
This trips up many people. Each format has its own quality scale. Quality 80 in AVIF is much higher quality than quality 80 in WebP.
| Format | Total at quality 80 | Total at matched quality |
|---|---|---|
| JPEG | 781 KB | 534 KB |
| WebP | 454 KB | 363 KB |
| AVIF | 648 KB | 205 KB |
Source: Digieh test, December 3, 2026, same six photos and Pillow encoders.
At quality 80, our AVIF files were bigger than WebP. At matched quality, AVIF was far smaller. Always compare formats by how they look, not by the quality number.
Which Format Encodes Fastest?
| Format | Average time per photo |
|---|---|
| JPEG | 12 ms |
| WebP | 140 ms |
| AVIF | 283 ms |
Source: Digieh test, December 3, 2026, average of three runs per photo on our cloud test machine with Pillow.
JPEG is by far the fastest. AVIF was about twice as slow as WebP here, but that only matters when you convert many images at once.
For a blog, you convert each image once. A fraction of a second is a small price for a much smaller file.
Do All Browsers Support WebP and AVIF?
| Format | Global support | Chrome | Firefox | Safari | Edge |
|---|---|---|---|---|---|
| WebP | 97.32 percent | 32 | 65 | 16.0 | 18 |
| AVIF | 96.71 percent | 85 | 93 | 16.4 | 121 |
Source: Can I use, WebP and Can I use, AVIF, read December 3, 2026. Numbers show the first fully supported version.
Almost all users can see both formats today. MDN still suggests a fallback for AVIF, because older devices exist.
Source: MDN Web Docs, Image file type and format guide, read December 3, 2026.
Free updates
Join the Digieh list
Be the first to know when our weekly brief launches.
No spam. Unsubscribe anytime. Read our Privacy Policy.
How Do You Serve AVIF With a Fallback?
Use the picture element. The browser picks the first format it supports, so older browsers get WebP or JPEG.
<picture>
<source srcset="photo.avif" type="image/avif">
<source srcset="photo.webp" type="image/webp">
<img src="photo.jpg" width="1438" height="810" alt="Describe the photo">
</picture>Always set width and height on the image. This stops the page from jumping while it loads.
Fighting layout shifts or slow loads? See our guide to the LCP issue: longer than 2.5s report.
Can You Use AVIF in WordPress?
Yes. WordPress added AVIF support in version 6.5, as long as your server’s image library supports it.
Source: Make WordPress Core, WordPress 6.5 adds AVIF support, read December 3, 2026.
You can check this in Tools, then Site Health, then Info, under the media section. If AVIF is missing, ask your host to update the image library.
If uploads fail, read our guide on the file type not permitted error.
What About PNG?
PNG keeps every pixel exactly, so it is great for logos and screenshots. For photos, it makes very large files.
| Format | Total size of our six photos |
|---|---|
| PNG, lossless | 7713 KB |
| JPEG, matched quality | 534 KB |
| AVIF, matched quality | 205 KB |
Source: Digieh test, December 3, 2026, with Pillow optimized PNG and the matched quality files above.
Our PNG files were about 37 times bigger than the AVIF files. Never upload photos as PNG unless you need every pixel exact. Convert them to AVIF or WebP first.
How Much Does This Matter for Page Speed?
Images are often the heaviest part of a web page. Smaller files download faster, especially on slow mobile data.
Try the calculator at the top with your own numbers. A page with 2,000 KB of photos could save about 1,232 KB per visit with AVIF, based on our test.
Smaller images also help your largest image show sooner. That can improve how fast the page feels to visitors.
Which Format Should You Use?
| Use | Best choice | Why |
|---|---|---|
| Blog and product photos | AVIF with fallback | Smallest files in our test |
| Simple setup, one file | WebP | Small files and near universal support |
| Email and old systems | JPEG | Works everywhere |
| Logos with transparency | WebP or PNG | Sharp edges and clear background |
Source: Digieh test, December 3, 2026, and MDN image format guide.
Want a quick win without code? Use our free image compressor and see our tips to speed up a WordPress site.
Which format does your site use most today?
- JPEG
- PNG
- WebP
- AVIF
- Not sure
Test Yourself
In our test, how much smaller was AVIF than JPEG at the same quality?
- About 10 percent
- About 62 percent
- About 95 percent
Across six photos matched at a similarity score of 0.95, AVIF totaled 62 percent less than JPEG.
Why can AVIF look bigger than WebP at quality 80?
- AVIF is always bigger
- Each format uses its own quality scale
- WebP removes color
Quality 80 in AVIF is a much higher quality level, so the file is larger.
Frequently Asked Questions
Is AVIF better than WebP?
For file size, yes. In our test AVIF was smaller than WebP for every photo at the same quality. WebP encodes faster and has slightly wider support.
Is WebP smaller than JPEG?
Yes. Our WebP files were 25 to 46 percent smaller than JPEG at the same quality.
Does AVIF lose quality?
AVIF is usually lossy, like JPEG. At matched quality, our AVIF files looked as close to the original as the JPEG files.
Should I still keep JPEG files?
Keep JPEG as a fallback and for email, where newer formats may not show.
Conclusion
AVIF gave the smallest files in our test, WebP came second and JPEG came last. Serve AVIF with a fallback, and judge quality by eye, not by the number.
Editor’s Note
This test is accurate as of December 3, 2026. Digieh ran it with the tools and settings listed above. Results depend on the photo and the encoder, so test a few of your own images too.
Spot an error in this article? Please contact us at support@digieh.com or read our Corrections Policy.
Keep exploring
Your next read is waiting
1AI & TechJavaScript QR Code Generator: Build It From Scratch8 min read
2BusinessMileage Log Template 2026: Free Tracker and Rates7 min read
3Visas & PassportsSchengen Visa Fee 2026: Official Costs and Calculator7 min read
4FashionWomen’s Clothing Size Chart: US, UK, EU Converter6 min read
5Home & KitchenRepair or Replace Washing Machine: Free Decision Calculator7 min read
6Finance & MarketsPrintable Monthly Budget Planner: Free Fill-In Sheet 20277 min readFound this useful?












