All Products
Search
Document Center

Object Storage Service:Advanced compression for HEIF or AVIF images

Last Updated:Mar 20, 2026

OSS converts images to High Efficiency Image File Format (HEIF) or AV1 Image File Format (AVIF) using advanced image codecs, achieving significantly higher compression ratios than JPEG. To trigger conversion, set the format parameter to heic or avif in an image processing URL.

Supported regions

Advanced image compression is available in the following regions:

  • China (Zhangjiakou)

  • China (Shanghai)

  • China (Hangzhou)

  • China (Shenzhen)

  • China (Beijing)

  • Singapore

  • US (Virginia)

Parameters

Set the format parameter to one of the following values in an image processing URL. OSS automatically applies advanced image compression when it detects either value.

ValueOutput format
heicHEIF
avifAVIF

Convert images to HEIF or AVIF

Append an image processing action to the object URL using the x-oss-process query parameter. Use format,heic to convert to HEIF or format,avif to convert to AVIF.

Convert JPEG to HEIF

The following URL converts a source JPEG image to HEIF at its original resolution (3924 x 2550):

https://image-demo-oss-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/pics/compression-demo.jpeg?x-oss-process=image/format,heic
demo

Convert JPEG to HEIF and resize

The following URL converts the same source image to HEIF and resizes it to 923 x 600:

https://image-demo-oss-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/pics/compression-demo.jpeg?x-oss-process=image/resize,l_923,h_600/format,heic

Compression results

File sizes after converting the source JPEG to HEIF at two resolutions:

FormatResolutionSizeCompression ratio
JPEG (source)3924 x 25502.09 MB
HEIF3924 x 2550268 KB87.5%
HEIF923 x 60030.7 KB98.6%