Image Resizer

Resize by pixels, percent, or a target file size, then convert format — processed on your device, nothing is ever uploaded.

100% private — your image is processed on this device and never uploaded.

Estimated file size

Dimensions
Change
Format

Worked examples

Email attachment

Shrinking a phone photo under a 5 MB limit

A phone camera shot is too large to attach to an email, so it's scaled down to Percent mode at half size with the quality slider pulled back a little.

Original
4032 × 3024 JPG, 3.6 MB
Scale
50%, quality 75%
Result
2016 × 1512

1.2 MB result — well under the limit

Website hero image

Hitting a strict page-weight budget

A developer needs a hero banner screenshot under 150 KB for page speed, so Target size mode searches for the WEBP quality that fits without shrinking the canvas.

Original
3840 × 2160 PNG, 2.4 MB
Target
150 KB, WEBP
Result
3840 × 2160, quality ≈62%

148 KB result, found in 8 tries

How it works

Every resize follows the same three steps. First, the file is decoded into a bitmap, reading its EXIF orientation tag so rotated phone photos come out upright. Second, that bitmap is drawn onto an off-screen canvas at the target width and height using high-quality bilinear resampling. Third, the canvas is encoded back into a file with canvas.toBlob() at your chosen format and quality.

Target size mode repeats step three with a binary search: it tries a quality in the middle of the possible range, checks whether the resulting file is under your target, and narrows the range toward whichever half still contains the answer. After about 8 rounds the gap is small enough that the result lands within a fraction of a percent of what's achievable at that pixel size.

quality ← binary search over [0, 1] until size(quality) ≤ target, 8 rounds ⇒ ±0.4% precision
Decode EXIF fix Resize on canvas Encode JPG/PNG/WEBP Download to your disk Target size mode loops step 3 with a binary search on quality.

Frequently asked questions

Does this resizer upload my photos anywhere?

No. The image never leaves your device — it's decoded and redrawn on an in-memory <canvas> using JavaScript that runs entirely in your browser tab. There is no upload request, no server processing, and no copy kept anywhere once you close the tab or pick a different file.

What's the difference between resizing by pixels, percent, and target size?

Pixels lets you type an exact width and height (with an optional locked aspect ratio). Percent scales the whole image up or down by a proportion of the original, so 50% always halves both dimensions. Target size flips the priority: instead of choosing dimensions, you choose a file size in KB and the tool searches for the JPEG or WEBP quality that gets as close as possible without going over, keeping the original pixel dimensions.

Why can't I hit an exact KB target?

The tool re-encodes the image at different quality levels and narrows in with a binary search — about 8 attempts, each roughly halving the gap to the answer, which lands within a fraction of a percent of your target. It can only shrink so far, though: once quality is pushed to its floor and the file is still bigger than your target, the only way to shrink further is to also reduce the pixel dimensions, which the target-size mode intentionally leaves untouched.

Why does PNG ignore the quality slider?

PNG is a lossless format — every pixel is preserved exactly, so its file size is driven by image complexity, not a quality dial. There's nothing for a quality search to adjust, which is also why PNG is unavailable while Target size mode is active: switch to JPG or WEBP for compression, or use PNG only with the Pixels/Percent modes for lossless resizing.

Will my photo be rotated wrong after resizing?

It shouldn't be — most phone cameras save a rotation flag in the photo's EXIF metadata instead of physically rotating the pixels, and this tool reads that flag automatically before drawing the image, so portrait photos stay upright the same way they appear in your gallery app.

Is there a limit to how large a photo I can resize?

It's bounded mainly by your device's memory and each browser's own canvas size ceiling (commonly around 16,000 pixels per side). Ordinary phone and camera photos — even 20-50 megapixels — process in well under a second on most computers; very large scans or exported TIFFs may take a moment longer or, on low-memory devices, fail to allocate a canvas that big.