Skip to main content

Min Width

Use the min-width transformation to ensure a delivered image variant is at least a target width.

Overview

min-width only changes the output when the source image is narrower than the requested minimum. It is useful when your app accepts small uploads but needs a minimum delivery size for some placements.

Syntax

FieldValue
Canonical parametermin-width
Aliasesmw, min_width
Accepted valuesInteger pixels from 1 through 8192

Example

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

Live examples

Original widthMinimum width 1800
Original transformation demo imageDemo image delivered with minimum width of 1800 pixels

Best practices

  • Use min-width when uploads vary and you only want to resize undersized images.
  • Pair it with enlarge=false when source quality matters more than meeting the minimum.
  • Use width when every variant should be delivered at the same planned width.

Common mistakes

  • Expecting min-width to resize already-wide images.
  • Upscaling small user uploads into large UI placements without checking quality.
  • Using min-width where a fixed Width is easier to reason about.

Last updated at: May 9, 2026