Specifies the desired output encoding for the image.
format parameter enables the source image to be converted (a.k.a., "transcoded") from one encoded format to another. This is useful when the source image has been saved in a sub-optimal file format that hinders performance.
|Baseline JPEG (also |
|Graphics Interchange Format|
|JPEG (also |
|Progressive JPEG (also |
|Portable Network Graphics|
|Portable Network Graphics palette image with 256 colors and 8-bit transparency|
- Automatic delivery of WebP format images via content negotiation can be enabled using the
auto=webpparameter. This will override the
formatparameter in browsers that support WebP. Although the WebP format produces images at a higher compression ratio with a lower loss of quality, it is not supported in all browsers.
- The source image can be any of the following image formats:
- JPEG, progressive JPEG, WebP (Lossy), and PNG8 have a sliding quality scale that supports the
- GIF and PNG do not have a sliding quality scale. They do not support the
- A progressive JPEG
pjpgis an image created using the JPEG suite of compression algorithms that will "fade in" successive waves of lines until the entire image has completely arrived. For this reason, progressive JPEG images typically appear to load quicker than the Baseline JPEG
- WebP support is available in Google Chrome, Mozilla Firefox 65 and later, Safari 14 and later, Opera, and Android Browser.
- Lossless compression is currently supported for WebP only.
- GIF to WebP conversion does not support animated GIFs.
- MP4 conversion is only available for animated GIF source images.
- AVIF is a premium feature of Fastly's Image Optimizer and choosing it as an encoding format will increase your bill. Specific charges will appear on your service order.
Click the links to view the transformed image using a demo Fastly IO service.