WebP rendition files are larger than JPEG files for some AEM Assets images
This article describes why WebP renditions generated in Adobe Experience Manager Assets may sometimes be larger than JPEG renditions, and provides steps to optimize WebP rendition sizes.
Description description
Environment
- Adobe Experience Manager Assets as a Cloud Service
- Assets Processing Profiles
Issue/Symptoms
When you generate image renditions with an AEM Assets Processing Profile, the WebP rendition isn’t guaranteed to be smaller than the corresponding JPEG rendition, even when both use the same source image and pixel dimensions.
Example:
- JPEG zoom rendition: 2048 × 1365, approximately 546 KB.
- WebP zoom rendition: 2048 × 1365, approximately 956 KB, at WebP Quality
85.
Cause
WebP and JPEG use different compression algorithms, and their quality values aren’t directly comparable. The resulting file size depends on the image content, encoder behavior, and quality setting. A WebP rendition therefore isn’t guaranteed to be smaller than a JPEG rendition. In a Processing Profile, the quality setting controls compression and affects the resulting file size.
Resolution resolution
Follow the steps below to address the issue:
- In AEM, go to Tools
>Assets>Processing Profiles. - Edit the Processing Profile that defines the WebP rendition.
- On the Image tab, locate the WebP rendition and lower its Quality value. For an initial test, change the source example from
85to70–75. - Reprocess a test asset and compare the JPEG and WebP rendition file sizes and visual quality.
- If the WebP file still exceeds your size target, test a lower quality value, such as
60–65. Compare file size and visual quality after each change. - Compare the actual delivered image responses, such as images delivered through EDS or direct asset URLs. Don’t compare only the static DAM renditions.
- If the page uses the AEM Core Image component, consider Web-Optimized Image Delivery instead of relying only on static DAM renditions. In the Image component policy, select Enable Web Optimized Images. Note: Web-Optimized Image Delivery applies to images rendered through the Core Image component in AEM as a Cloud Service. It changes the image delivered to the page; it doesn’t change the static WebP rendition generated by the Processing Profile.
- Confirm that the delivered WebP image meets your file-size and visual-quality requirements.