All Products
Search
Document Center

CDN:Adjust image quality

Last Updated:Jul 21, 2026

Reduce image file sizes and lower transfer costs by adjusting image quality through Alibaba Cloud CDN's image editing feature. Quality adjustment supports two methods: automatic compression, and URL-based quality parameters.

Note

The image editing feature of Alibaba Cloud CDN, the image editing feature of Dynamic Content Delivery Network (DCDN), and the Image Processing (IMG) feature of Object Storage Service (OSS) are three separate features and cannot be used interchangeably.

Note

Image editing is a paid service and is free of charge until further notice.

Automatic compression

Automatic compression reduces file size without changing image dimensions or format. For setup instructions, see Enable and use image editing.

Quality parameters

Quality transformation applies only to JPG and WebP images. Set the action to quality and use one of the following parameters.

Parameter reference

Parameter

Description

Valid values

Q

Absolute quality value. Sets a quality ceiling — output quality is whichever is lower: the target value or the original quality. Quality can only be lowered, not raised.

Multiples of 5 in the range 0–100 (other values are not supported). Higher values produce better quality and sharpness. 95 is recommended.

q

Quality coefficient. Multiplies the original quality by the specified percentage to calculate the output quality.

Multiples of 5 in the range 0–100 (other values are not supported). Higher values produce better quality and sharpness. 95 is recommended.

Examples

Absolute quality (`Q`)

http(s)://example.com/image01.jpg?image_process=quality,Q_90

Q sets a quality ceiling. If the original quality is already below the target value, the original quality is kept.

Original quality

Target (Q_90)

Output quality

95

90

90 (reduced to target)

80

90

80 (original kept — cannot increase)

Quality coefficient (`q`)

http(s)://example.com/image01.jpg?image_process=quality,q_90

q scales quality relative to the original. The output quality equals the original quality multiplied by the coefficient.

Original quality

Coefficient (q_90)

Output quality

80

90%

80 × 90% = 72

What's next

Enable and use image editing