Skip to main content

Chroma Subsampling

Use the chroma_subsampling transformation to control JPEG chroma subsampling for a delivered image variant.

Overview

Chroma subsampling affects how JPEG output stores color detail. 4:2:0 usually produces smaller files, while 4:4:4 preserves more color detail. Use auto when you want Imgwire's encoder policy to choose the setting.

Syntax

FieldValue
Canonical parameterchroma_subsampling
Accepted values4:2:0, 4:4:4, auto
Applies toJPEG output

Example

https://cdn.imgwire.dev/{organization_id}/{environment_id}/{image_id}?format=jpg&chroma_subsampling=4:4:4
image.url({
format: 'jpg',
chroma_subsampling: '4:4:4',
quality: 85,
});
imgwire images url img_123 --format jpg --chroma-subsampling 4:4:4 --quality 85

Live examples

4:2:0 JPEG4:4:4 JPEG
Demo image delivered as JPEG with 4:2:0 chroma subsamplingDemo image delivered as JPEG with 4:4:4 chroma subsampling

Best practices

  • Use auto for most application images.
  • Use 4:4:4 when color edges or generated graphics need stronger color fidelity.
  • Test file size and visual quality together; this setting is a compression tradeoff.

Common mistakes

  • Expecting this setting to affect WebP, AVIF, or PNG output.
  • Using 4:4:4 globally without measuring the file-size impact.
  • Comparing variants at different quality values and attributing the difference only to subsampling.

Last updated at: May 9, 2026