Skip to main content

Zoom

Use the zoom transformation to enlarge a focused area of a delivered image variant.

Overview

Zoom is useful for thumbnails, previews, and generated image variants where the subject should occupy more of the frame. Combine zoom with gravity when the important content is not centered.

Syntax

FieldValue
Canonical parameterzoom
Aliasz
Value syntaxfactor, factor:gravity, or an SDK object with factor and optional gravity

Example

https://cdn.imgwire.dev/{organization_id}/{environment_id}/{image_id}?zoom=1.5:attention
image.url({
zoom: '1.5:attention',
format: 'auto',
quality: 'auto',
});
imgwire images url img_123 --zoom 1.5:attention --format auto --quality auto

Live examples

These examples use a wide off-center astronaut portrait so attention-based zoom has a clear subject to target.

Original1.25x center1.5x attention
Wide off-center astronaut portrait source imageWide off-center astronaut portrait zoomed around the centerWide off-center astronaut portrait zoomed using attention gravity

Best practices

  • Use zoom with gravity when the subject should stay in frame.
  • Keep zoom factors modest for thumbnails so the image remains recognizable.
  • Pair zoomed variants with explicit dimensions when used in fixed-size UI.

Common mistakes

  • Zooming without checking that the important content remains visible.
  • Using zoom when a crop would be more predictable.
  • Applying one zoom value to very different user-generated images.

Last updated at: May 9, 2026