AEM Assets: Smart Crop renditions not generated for assets with incorrect file extensions

Learn how to resolve the issue when Smart Crop renditions aren’t generated in AEM Assets when the file extension doesn’t match the actual file format.

Description description

Environment

Adobe Experience Manager (AEM) Assets (Cloud Service)

Symptoms

  • After running the Update Metadata workflow and reprocessing assets, some assets don’t generate Smart Crop renditions as expected.
  • The issue occurs when assets have a .jpg extension but are actually in WEBP format.
  • Log entries indicate that Smart Crops weren’t generated because image height and width couldn’t be processed.
  • Tools such as exiftool may reveal the true file type and MIME type as image/webp despite the .jpg extension.

Cause

Smart Crop renditions aren’t generated when the asset’s actual file type isn’t supported as an input format by Dynamic Media, even if the file extension suggests otherwise. WEBP files with a .jpg extension aren’t processed for Smart Crops.

Resolution resolution

Follow the steps below to resolve the issue:

  1. Validate the actual file type of the asset:

    • Download the affected asset from AEM Assets.

    • Use a tool such as exiftool to inspect the file type and MIME type.

    • Confirm whether the file type matches the file extension (For example: .jpg should be image/jpeg).

  2. Review supported file formats for Smart Crop:

    • Refer to the official documentation on supported input formats for Dynamic Media Smart Crop: Dynamic Media Image Profiles

    • Note that WEBP is only supported as an output format, not as an input format for Smart Crop processing.

  3. Correct the asset file format:

    • If the asset is in WEBP format but named with a .jpg extension, convert the file to a supported format (For example: JPEG or PNG) and re-upload it to AEM Assets.

    • Alternatively, ensure that the file extension and MIME type are consistent and supported.

  4. Reprocess the asset:

    • After correcting the file format, re-run the Update Metadata workflow or reprocess the asset to trigger Smart Crop generation.
recommendation-more-help
experience-cloud-kcs-help-kbarticles