WebP vs JPEG vs AVIF in 2026: which image format to actually use
Three image formats, three sets of trade-offs, and a lot of confident-sounding advice on the internet that is out of date or wrong. Here is what each format actually does, where it wins, where it loses, what current browsers and platforms support, and how to pick without overthinking it.
The image-format question keeps getting asked because the answer keeps shifting. WebP was the right modern default for years; then AVIF arrived, browser support caught up, and a lot of the older comparison articles became misleading. Most of what is on the first page of search results is either out of date, sponsored by whoever sells the encoder being benchmarked, or written by someone who tested one image and generalised. The actual answer is a small handful of rules that depend on what the image is and where it is going.
This piece is the version I would want to send to a designer, a developer, or anyone running a personal site who has noticed their images load slowly and is not sure whether to switch formats. It covers what each format is, what it is good at, where it falls down, what the current browser and tooling support actually looks like, and a short flowchart for picking. It is opinionated where the evidence is clear and hedges where it isn't.
What each format actually is
JPEG (1992, ITU-T T.81 / ISO/IEC 10918)
The original lossy photographic image format. JPEG uses a discrete cosine transform on 8x8 blocks of pixels, quantises the result, and entropy-codes the coefficients. The 8x8 block structure is why heavy JPEG compression produces the characteristic blocking artefacts visible in low-quality photos and the ringing around sharp edges in screenshots and text. The format is supported everywhere - every browser, every operating system, every camera, every email client, every image editor written since the mid-1990s. There is no realistic compatibility risk in shipping a JPEG.
JPEG is also the format your phone camera saves to by default (or HEIC, which is JPEG's successor in spirit but a different format - more on that below). For photographic content at moderate to high quality, JPEG is fine. For flat graphics, screenshots, line art, and anything with sharp edges and large flat colour areas, JPEG is a poor choice and produces visible ringing.
PNG (1996, RFC 2083 / ISO/IEC 15948)
Lossless, supports transparency, designed originally as a free replacement for GIF. PNG is the right choice for screenshots, line art, diagrams, icons, and anything you need pixel-exact. It is a poor choice for photographic content, where lossless compression produces enormous files compared with any modern lossy format. Transparency support and broad compatibility are PNG's main reasons for sticking around in 2026.
WebP (2010, RFC 6386 for VP8-derived lossy, plus a separate lossless mode)
Google's image format, derived from the intra-frame coding of the VP8 video codec. WebP has two modes: lossy (similar coding model to a single video frame) and lossless (a separate engine designed specifically for images). Both are smaller than their JPEG/PNG equivalents in the typical case, often by a substantial margin: 25-35% smaller than JPEG at matched quality is a reasonable rule of thumb, and the lossless mode often beats PNG by 25% or more.
WebP supports transparency, animation (a GIF replacement, in practice rarely used for animation in 2026), and a 0-100 quality scale that maps fairly intuitively to perceived quality. It encodes quickly. It is supported in every current browser. It is supported by most modern image editors and CMS platforms. It has been a stable, boring format since the mid-2010s.
AVIF (2019, AV1 Image File Format)
AVIF is a single still frame encoded with the AV1 video codec, wrapped in a HEIF container. AV1 was designed by the Alliance for Open Media (Google, Netflix, Amazon, Apple, ARM, Cisco, Intel, Microsoft, Mozilla, Nvidia, Samsung, and others) as a royalty-free successor to HEVC, and the still-image version inherits AV1's compression efficiency.
On photographic content, AVIF reliably produces files that are 30-50% smaller than JPEG and 20-30% smaller than WebP at matched perceptual quality, depending on the encoder settings and the specific image. It supports transparency, wide colour gamuts (Rec. 2020, HDR), 10- and 12-bit colour depth, and several other features that matter to professional workflows. Browser support is universal in 2026, and the format is the modern default for any new image-heavy website being built today.
The trade-off is encoding speed: high-quality AVIF encoding is slow (orders of magnitude slower than JPEG, several times slower than WebP), and tooling outside the browser still lags. Many desktop image viewers, file pickers, and legacy CMSes cannot open AVIF directly without a plugin or a recent OS update. For images that live entirely on the web, this does not matter. For files people will download and open locally, it sometimes does.
HEIC (the iPhone format, briefly)
HEIC is the iPhone's default photo format since iOS 11. It uses HEVC (H.265) compression in a HEIF container - similar idea to AVIF but with a different, patent-encumbered codec. HEIC produces smaller files than JPEG at the same quality, but is poorly supported outside Apple's ecosystem, which is why sharing an iPhone photo to a Windows machine, a Linux desktop, or a web form often produces a "this format is not supported" error. HEIC is not a web-delivery format and is not in this comparison; if you have a stack of HEICs you need to convert, the HEIC-to-JPEG converter does it locally without uploading.
Compression: how big is the difference, really?
Numbers vary by image, by encoder settings, and by the perceptual-quality metric used to define "matched quality." The widely cited benchmarks (Netflix's 2020 AVIF analysis, Cloudflare's encoder comparisons, the AVIF-Comparator reference suite, repeated independent tests in 2023-2025) converge on the following rough picture for photographic content at typical web quality:
- JPEG vs WebP: WebP averages 25-35% smaller at matched perceptual quality. Bigger gains at low bitrates, smaller gains at high bitrates.
- JPEG vs AVIF: AVIF averages 40-50% smaller at matched perceptual quality. The gap is largest at low bitrates and shrinks at very high quality where both formats become near-lossless.
- WebP vs AVIF: AVIF averages 20-30% smaller. Encoding takes 5-10x longer.
Two important caveats. First, these are averages: individual images can swing the result by 20 percentage points either way. A photo of a face does not compress like a screenshot does not compress like a starfield does not compress like a cartoon. Second, "matched perceptual quality" depends on the metric, and the field is split between SSIM, MS-SSIM, VMAF, and butteraugli. AVIF's lead narrows under SSIM and widens under VMAF; WebP's lead over JPEG holds across all common metrics.
For non-photographic content - screenshots, UI captures, line art, text-heavy images - the picture changes. WebP's lossless mode is often the smallest. PNG is competitive at the cost of larger files. JPEG's blocking artefacts make it the worst choice. AVIF works but offers smaller gains than on photos.
Browser and tooling support in 2026
The browser story is settled. According to caniuse.com data current as of mid 2026:
- JPEG: 100% support. There is no browser, mobile or desktop, that cannot render a JPEG.
- PNG: 100% support, same as JPEG.
- WebP: Effectively 100% in modern browsers. Chrome since 2010, Opera since 2010, Edge since 2018, Firefox since 2019, Safari (desktop and iOS) since 2020. The remaining gap is users on Windows 7-era browsers who are also locked out of most of the modern web.
- AVIF: Chrome since 2020, Opera since 2020, Firefox since 2021, Safari (desktop and iOS) since 2022, Edge since 2023. Mobile coverage followed within months of each desktop launch. As of 2026, AVIF support sits above 95% of global browser users on web.dev's tracking, with the holdouts being older Samsung Internet builds and a tail of un-updated mobile devices.
The tooling story lags the browser story by a year or two. Most current image editors (Photoshop with the AVIF plugin, Affinity Photo 2, GIMP recent versions, Krita, Pixelmator Pro) handle both WebP and AVIF natively. Most CMSes (WordPress 6.5+, Ghost, Statamic, Contentful) accept WebP and AVIF uploads. Operating-system file viewers were the last to catch up: macOS Sonoma and later, Windows 11 with the AV1 Video Extension installed, and most current Linux desktops can open AVIF files in their default viewers. Older OS releases often cannot, which is why "what format should I send?" is sometimes a different question from "what format should I serve from a website?".
Picking a format: a small flowchart
If the image will be served from a website
Use the <picture> element with multiple <source> entries, in order of preference: AVIF first, WebP as a fallback, JPEG (or PNG for transparent or lossless content) as the final fallback. Browsers that support AVIF will pick it; older browsers will fall through. This is the standard, well-supported pattern, costs nothing in bandwidth (only the chosen format is downloaded), and handles every browser from 2010 to today.
If you only want to ship one format, ship WebP. It loses to AVIF on size but wins on encoder simplicity, broader tooling support, and faster build times, and it still beats JPEG by a wide margin.
If the image is a screenshot, UI capture, or line art
Use WebP-lossless first (smallest file, no quality loss, broad support); fall back to PNG if the consumer might not handle WebP. Avoid JPEG, which produces ugly ringing around sharp edges and text.
If the image needs transparency
WebP and AVIF both support alpha and produce dramatically smaller files than PNG for the same image. PNG only when the consumer cannot handle either modern format - which, on the open web, is almost no one.
If the image is going to a person, not a website
Use JPEG. The recipient may be opening the file in an email client, a phone photo viewer, a Word document, or a printer, and you do not control which decoders are installed on their machine. JPEG is the only format that opens in literally everything. The size penalty for sending JPEG instead of WebP or AVIF almost never matters at the level of one-off file sharing.
If you have a folder of HEIC photos from an iPhone
Convert to JPEG (for compatibility) or to WebP/AVIF (for size) before uploading anywhere. The HEIC converter on Privvert does this locally - the photos never leave your device, which matters more for original-quality photos than for already-published images, because the originals carry full EXIF including GPS coordinates. Strip metadata afterwards with the EXIF tool.
What "convert to WebP/AVIF" actually involves
Converting an image is fundamentally re-encoding: the source is decoded to pixels, then re-encoded with the target format's encoder. Two things matter for quality.
First, do not re-encode at maximum quality blindly. The source already lost information when it was first encoded; re-encoding at quality 100 just preserves the existing artefacts at the cost of a much larger file. For photographic content, re-encoding at the AVIF or WebP equivalent of "JPEG quality 80-85" is almost always the sweet spot. You will not see the difference at viewing size, and the file shrinks.
Second, do not re-encode the same image multiple times if you can avoid it. Each re-encode introduces fresh quantisation noise. If you have a master JPEG and want both a WebP and an AVIF for the web, encode each from the JPEG master, not from each other. If you have the original RAW or PNG, encode all three from that.
For batch jobs - converting a folder of holiday photos, a stack of screenshots, a CMS image library - the image format converter and image compressor on Privvert run the official libwebp and libavif encoders compiled to WebAssembly, so the conversion happens in your browser without the files being uploaded. You can pair them with the image resizer to drop large camera originals down to a sensible web size before encoding - which often shrinks the output more than the format choice does.
The trap: comparing formats at "the same quality number"
If you only take one thing from a comparison article, take this: the quality-setting slider in your image editor or converter is not portable between formats. JPEG's "quality 80" and AVIF's "quality 80" target different quantisation regimes and produce different visual results. Setting all three encoders to "80" and comparing the outputs is comparing apples, oranges, and a small banana.
The right way to compare is to fix a target file size, encode each format to approximately that size, and then compare the visual output. Or, more practically, fix a visual quality bar (open both files at viewing size; can you see a difference?) and compare the resulting file sizes. Comparing at "the same quality number" produces results that look like the modern formats are worse than they are, and is responsible for a lot of the "AVIF looks bad on my photo" reports floating around the internet.
Frequently asked questions
Which format is smallest at the same visible quality?
AVIF, by a meaningful margin, especially on photographic content. In published comparisons (Netflix, Cloudflare, the AVIF reference test set), AVIF averages roughly 50% smaller than JPEG and 20-30% smaller than WebP at matched perceptual quality. The gap shrinks on flat graphics and synthetic images, where WebP's lossless mode is sometimes the smallest. JPEG is rarely the smallest at any quality target, but it is the most universally supported.
Can I just use AVIF for everything in 2026?
Browser-side, yes - every current major browser (Chrome, Firefox, Safari, Edge, Opera, mobile Safari, Chrome Android) supports AVIF, and has for at least a year. The remaining problems are outside the browser: many CMSes, image-editing tools, and operating-system file pickers still cannot open AVIF, and a small but non-zero share of users on older OS installs cannot view AVIFs in their default viewers. For a website served to current browsers, AVIF is fine. For files you send to other people who will open them in Preview, Photos, or an email client, JPEG is still the safe default.
Is WebP still worth using if AVIF is better?
Often, yes. WebP encodes much faster than AVIF (typically 5-10x at comparable settings), is supported by an even broader set of tools, has been a stable web format since 2010, and has both a lossy and a lossless mode that share one container. For build pipelines that re-encode thousands of images on every deploy, the encoding-time difference is real. For small static sites it does not matter. WebP is also the better default for screenshots and UI imagery, where its lossless mode often beats both AVIF and PNG.
Does using WebP or AVIF hurt SEO?
No. Google has supported WebP in Search and Image Search since 2010, supports AVIF, and explicitly recommends modern image formats in its Core Web Vitals guidance because smaller files improve Largest Contentful Paint. The standard <picture> + <source> pattern lets you serve AVIF or WebP to browsers that support them and JPEG to those that do not, with no SEO penalty in any direction.
What about transparency? Don't I need PNG for that?
All three modern formats support transparency. WebP and AVIF both encode alpha channels and produce dramatically smaller files than PNG for the same image. PNG remains useful for: pixel-perfect screenshots where any lossy artefact matters, line art and diagrams that compress poorly under photographic codecs, and contexts where the consuming tool cannot read WebP or AVIF. For typical web transparency (logos, icons, decorative cutouts), WebP-lossless or AVIF beats PNG on file size with no visible difference.
How do I convert a folder of JPEGs to WebP or AVIF without uploading them?
Drag them into an in-browser image converter that runs the encoder locally. Privvert's image converter uses WebAssembly builds of the official libwebp and libavif encoders, so the conversion happens in your browser tab without the files leaving your device. You can verify this by opening the browser's developer tools, switching to the Network panel, and watching that no upload of the file size occurs when the conversion runs.
Why does my AVIF file look worse than my JPEG at the same 'quality 80' setting?
Because the quality scales are not comparable. JPEG quality is a 0-100 quantisation parameter unique to JPEG. AVIF quality is a different scale (often 0-63 internally, mapped to 0-100 by tools), and 'quality 80 AVIF' is not the same target as 'quality 80 JPEG'. To compare fairly, encode at several quality settings, measure the file sizes, and pick the AVIF setting that produces a file similar in size to your reference JPEG - then compare the resulting visual quality. AVIF will almost always look better at the same file size, even when 'the same quality number' looks worse.
Putting it together
For a website in 2026, the right default is to serve AVIF to browsers that accept it, WebP as a fallback, and JPEG as a final fallback for the rare decoders that handle neither. For files you send to other people, JPEG remains the safe default. For screenshots and graphics, WebP-lossless or PNG. For HEIC photos from an iPhone, convert before sharing - and strip the metadata while you are there.
You can run all of the above locally without uploading anything: the image converter, compressor, resizer, and HEIC converter on Privvert all run in your browser tab. There is more in this vein on the blog, including a longer piece on why local processing is the right default for any file you would not email to a stranger.