How to resize an image to exact pixels

Getting a photo to an exact width and height, not just smaller, needs a different setting than a normal resize. Here is how, with no software to install.

Updated · 2 min read

Why "resize" alone is not enough

Most resize tools, including phone Photos apps, scale an image down to fit inside a maximum width or height while keeping its original proportions. That is the right behavior for shrinking a photo for the web, but a field that asks for an exact size, such as a 1920x1080 banner or a 512x512 app icon, means the output must be precisely that width and height, whatever shape the source photo started as. A plain resize that respects the aspect ratio cannot hit an odd exact size on its own; the image has to be cropped, padded, or stretched to fit.

The three ways to force an exact size

There is more than one way to fill an exact box, and the right choice depends on whether cropping or distortion is the lesser problem for that photo:

  • Crop to fill: scale the image up until it covers the exact box, then cut off whatever hangs over the edges. No blank space, but some of the photo is lost at the sides or top and bottom.
  • Fit inside with padding: scale the image down until it fits entirely inside the box, then fill the leftover space with a background colour (usually white or black). Nothing is cropped, but bars appear on two sides unless the source is already the right shape.
  • Stretch: force the image to the exact width and height regardless of its original proportions, which distorts anything that is not already close to that shape.

In Photoshop or a phone editor

Photoshop's Image Size dialog can set exact pixel dimensions but needs the constrain-proportions box unchecked to avoid stretching, and does not crop or pad automatically, so getting a non-matching aspect ratio to look right still takes manual cropping first. Most phone editors only offer preset crop ratios (1:1, 4:5, 16:9), not an arbitrary exact pixel size.

Setting an exact size in the browser

Stayput's resize image tool has an Exact size mode: type the width and height you need, and choose whether a mismatched photo is cropped to fill, fit with padding, or stretched. Ready-made pages cover the sizes people ask for most, such as 1920 by 1080 for a banner or wallpaper and 1024 by 1024 for an app icon, with the exact size already set. Everything happens in the browser, so a batch of photos resizes at once with nothing uploaded.

Questions

What is the difference between resizing and cropping to an exact size?

Resizing to a maximum keeps the photo's original shape and only makes it smaller; forcing an exact size (like 1920x1080) usually needs cropping, padding or stretching, since the source photo is rarely already that exact shape.

Will resizing to an exact size distort my photo?

Only if you choose Stretch. Crop to fill and Fit with padding both keep the photo's proportions intact; they just handle the leftover space differently, by cutting it off or by adding a border.

Can I resize many photos to the same exact size at once?

Yes, with a browser tool like Stayput's resize image, which applies the same exact-size setting to every photo you drop.

Can this make a small image bigger to hit the exact size?

Yes. Exact size can enlarge: type a width and height larger than the photo and it is stretched to that size, but no detail is added, so it looks soft. For a sharper result, run the photo through an AI image upscaler first, then resize to the exact dimensions. Limit dimensions and Percentage only scale down.

Tools mentioned in this guide

More guides