Skip to main content

image/avif

image

The MIME type for AVIF images. AVIF (AV1 Image File Format, 2020) provides superior compression to both JPEG and WebP – typically 50% smaller than JPEG at equivalent quality. Supports HDR, wide color gamut, and alpha transparency. Supported in Chrome 85+, Firefox 93+, Safari 16+. The best-quality modern web image format.

Details

AVIF is based on the AV1 video codec key frames. Defined by the Alliance for Open Media (AOM), the same group behind the AV1 video codec.

Compression vs JPEG at equivalent quality: - AVIF lossy: ~50% smaller than JPEG - AVIF vs WebP: AVIF is typically 20–30% smaller than WebP

Features: - HDR (high dynamic range) support - Wide color gamut (BT.2020) - Full alpha transparency - 8-bit, 10-bit, and 12-bit color depth

Browser support: Chrome 85+ (2020), Opera 71+, Firefox 93+ (2021), Safari 16+ (2022), Edge 121+. Universal modern browser support as of 2023.

Encoding speed: AVIF is slower to encode than WebP or JPEG. For dynamic image generation, WebP may be more practical. For CDN-optimized static image serving, AVIF is the best choice.

Delivery: <picture><source type="image/avif" srcset="img.avif"><source type="image/webp" srcset="img.webp"><img src="img.jpg"></picture>

Common use

Modern web images where maximum compression quality matters, CDN static assets

See Also