What this tool does
Resizing an image to a stated pixel size sounds trivial, and the usual approaches get it subtly wrong. Scaling both dimensions proportionally hits the width but not the height. Stretching hits both but distorts the subject. This tool resizes to an exact width and height using whichever method you choose, and always reports the final dimensions and file size so you know what you are submitting.
How it works
There are three distinct behaviours, and picking the wrong one is the source of most bad results. Fit scales the image down until it fits inside the target box, preserving the aspect ratio, so the result may be smaller than the target in one dimension. Fill covers the whole target box and crops the overflow, preserving the aspect ratio. Stretch forces both dimensions to match and distorts the image unless the aspect ratios already agree.
Aspect ratio is the ratio of width to height. A 3:2 photo and a 1:1 target have incompatible ratios, so something must give: either letterbox bars, crop the edges, or distort. For profile photos, Fill is usually right because the subject stays undistorted. For a full-bleed banner, Fit with a matching target ratio is usually right.
Upscaling cannot invent detail. Enlarging beyond the source resolution produces a larger file that looks softer and no sharper, and a portal that checks dimensions does not care that the extra pixels are invented. This tool will resize up if you ask, but it will tell you when the result is being enlarged.
Worked example
Resizing a 4000×3000 photo down to exactly 200×230 pixels for an exam application form.
- Source aspect ratio = 4000 / 3000 = 1.333
- Target aspect ratio = 200 / 230 = 0.870
- Ratios differ, so Fit or Fill must letterbox or crop
- Using Fill: scale to cover 200 wide, crop the height
Fill produces exactly 200×230 with the image cropped vertically and no distortion. Fit would instead give 200×150 inside a 200×230 box, which most portals would reject on the height requirement.
Accuracy and limitations
- Upscaling adds no real detail. If a portal checks dimensions only, it will accept an upscaled file that looks worse than the original.
- Resizing always re-encodes, so a small amount of quality is lost each time. Converting from PNG to JPEG will usually shrink the file dramatically for photographic content.
- Colour profiles embedded in the source may be dropped by the browser's encoder, which can shift colour slightly in some viewers.
Frequently asked questions
- Should I use fit, fill, or stretch?
- Fill for profile photos and avatars, so the subject is not distorted and the box is exactly filled. Fit for images where you want the whole picture kept and letterboxing is acceptable. Stretch only when the source and target aspect ratios already match, otherwise it distorts.
- Why did my resized image come out the wrong size?
- Fit mode preserves the aspect ratio, so it hits the target in one dimension and is smaller in the other. That is correct behaviour, not a bug. If a portal needs an exact height too, use Fill so both dimensions match.
- Can I make an image bigger without it looking worse?
- Not meaningfully. Enlarging interpolates the pixels you already have, so the file gets larger and the image gets softer. It only helps when the requirement is a minimum dimension, such as a print size at a given DPI.
- Does resizing reduce quality?
- Slightly, because the image is decoded and re-encoded. The loss compounds if you resize the same file repeatedly, so it is worth keeping one master copy and resizing from that each time rather than chaining operations.
- Are my images uploaded?
- No. Decoding, resizing, and re-encoding all happen in your browser via the canvas API. Nothing is transmitted.