AVIFify

AVIF

.avif

The open, royalty-free AV1-based image format that delivers the smallest files at a given quality, with alpha transparency, animation, and HDR built in.

rasterbothTransparencyAnimation95% browser support

AVIF stores a photograph in roughly half the bytes of a JPEG at the same visual quality, and 20–25% fewer bytes than WebP. It is the still-image profile of the royalty-free AV1 video codec, standardised by the Alliance for Open Media in 2019. This page covers the compression numbers, the features no older web format offers, the encoding cost, and a decision framework for when AVIF is — and isn't — the right format.

Convert images to and from AVIF in your browser, with no upload: Convert JPG to AVIF, Convert PNG to AVIF, Convert AVIF to JPG, Convert AVIF to PNG.

What AVIF is

AVIF is a container that wraps AV1 intra-frame-coded image data in the ISOBMFF box structure shared by MP4 and HEIC. Three facts define it:

  • AVIF derives from the AV1 video codec — every still is one keyframe.
  • AOMedia publishes AVIF royalty-free, removing the patent friction that slowed earlier formats.
  • The .avif file carries colour, depth, alpha, and animation in one ISOBMFF container.

The MIME type is image/avif. The codec is AV1; the wrapper is ISOBMFF.

How much smaller AVIF is

AVIF wins on compression at every quality target tested in 2025–2026 benchmarks. Typical results for photographic content at matched SSIM quality:

FormatSize vs JPEGNotes
AVIF~50% smallerLargest savings at low and medium bitrates
WebP25–34% smallerAVIF is a further 20–25% smaller than this
JPEGbaseline1992 DCT baseline

The advantage is widest where bytes matter most: heavily compressed thumbnails, hero images on slow connections, and gradient-heavy graphics where AVIF's wider transform set suppresses banding. At very high quality (q≈90+) the gap narrows, because all codecs converge toward near-lossless. See AVIF vs WebP and AVIF vs JPG for matched-quality test images.

Features older web formats lack

AVIF ships 5 capabilities that JPEG, PNG, and even WebP only partially match:

  • 10-bit and 12-bit colour — more tonal precision, far less gradient banding than 8-bit JPEG/WebP.
  • HDR and wide gamut — BT.2020 and Display P3 colour spaces with PQ/HLG transfer functions.
  • Alpha transparency — full 8/10/12-bit alpha, like PNG, at a fraction of the size.
  • Animation — multi-frame image sequences using AV1's inter-frame tools.
  • Film grain synthesis — grain is removed before encoding, then re-added on decode from a compact model, saving bytes that grain would otherwise make incompressible.

Film grain synthesis is unique to the AV1 family and is why AVIF excels on noisy film scans and high-ISO photography. WebP offers none of these beyond basic alpha and animation.

The encoding cost

AVIF's savings come from heavier computation. Encoding is 5–20× slower than WebP at comparable effort: a 1200×800 photo that takes ~200ms as high-effort WebP can take 5–20 seconds as high-effort AVIF. Decoding is also slower, most noticeably on low-end mobile CPUs.

Three mitigations cover most cases:

  • Encode once — heroes and product photos justify slow, high-quality encoding.
  • Lower the effort for build pipelinesavifenc --speed 6 trades a little size for large time savings.
  • Offload to a CDN — Cloudflare, Cloudinary, Imgix, and Vercel encode on the fly and cache the result.

Always measure decode time on real target devices; transfer savings can be partly offset by decode on weak hardware. The AVIF Compression Settings guide covers the speed/quality parameters in detail.

Browser support in 2026

AVIF reaches ~94% of global users as of 2026, per caniuse. Support timeline:

  • Chrome and Edge — since version 85 (August 2020).
  • Firefox — since version 93 (October 2021).
  • Safari — since version 16 / iOS 16 (September 2022).

The remaining ~6% are iOS 15-and-older devices, locked-down corporate Windows builds, and some in-app browsers. Ship AVIF with a WebP or JPEG fallback and that tail is covered automatically. The AVIF Browser Support guide details the fallback patterns.

When to choose AVIF — and when not to

Choose AVIF when minimum bytes or maximum fidelity is the priority:

  • New sites where you control the delivery pipeline.
  • Image-heavy pages where cumulative savings improve Core Web Vitals.
  • HDR, wide-gamut, or gradient-heavy content where 10/12-bit depth matters.
  • Any site already on a modern image CDN that auto-negotiates formats.

Keep another format when the codec overhead outweighs the win:

  • Favicons and tiny icons — container overhead approaches the payload; use PNG or ICO.
  • Pure vector artworkSVG stays sharp at any size and is smaller.
  • Editing masters — re-encoding compounds loss; keep a lossless source and export AVIF on demand.

How to ship AVIF

Serve AVIF first, with fallbacks, using the <picture> element. The browser picks the first format it supports:

<picture>
  <source type="image/avif" srcset="/photo.avif" />
  <source type="image/webp" srcset="/photo.webp" />
  <img src="/photo.jpg" alt="…" width="1200" height="675" loading="lazy" decoding="async" />
</picture>

Framework and platform paths:

  • Next.js — set images.formats to ["image/avif", "image/webp"]; next/image negotiates automatically. See AVIF in React.
  • WordPress — native AVIF upload landed in 6.5 (April 2024). See AVIF on WordPress.
  • Shopify — see AVIF on Shopify.

Convert to AVIF now

These converters run entirely in your browser — the image never leaves your device:

Sources and further reading