πŸ–ΌοΈ Image Resizer

Resize images to exact pixel dimensions with aspect-ratio lock, then export as JPEG, WebP or PNG in your browser.

πŸ–ΌοΈ

Drop your image here Release to upload

or click to browse your files

JPEG PNG WebP GIF

Max file size: 30 MB

πŸ–ΌοΈ

Upscaling beyond the original size may result in a blurry image.

Smaller file Better quality

PNG is lossless β€” quality is always 100%.

Original
Original
Resized
Resizing…
Resized
Set dimensions and click Resize
Original dims
New dims
Original size
Output size

About Image Resizer

  • β€’ Resize images to any custom width and height using your browser's Canvas API.
  • β€’ Lock ratio β€” keeps width and height proportional so the image isn't distorted.
  • β€’ Free resize β€” unlock the ratio to set any width and height independently.
  • β€’ Supports JPEG, PNG, and WebP output. GIF input is converted to a static image.
  • πŸ”’ Your images are processed entirely in your browser β€” nothing is sent to any server.

How resizing works with the Canvas API

When you select a file, the image is decoded in the browser and its natural width and height are read, along with the file size in bytes. The ratio of width to height is stored so the aspect-ratio lock can maintain it.

Resizing creates an off-screen canvas at exactly the target width and height, then draws the decoded image into it scaled to fill that canvas. The browser's own image-scaling routine does the interpolation. The canvas is then encoded to a blob in the chosen format, and for JPEG and WebP the quality value you set is passed to the encoder as a number between zero and one. PNG has no quality parameter because it is lossless, so the slider is hidden when PNG is selected.

With the ratio lock engaged, typing a width recalculates the height by dividing it by the stored ratio, and the height field becomes read-only. Unlocking frees both fields, allowing deliberate distortion when you need a specific frame. Preset buttons set the width and let the height follow.

Because every step happens on the canvas inside the page, the original file stays on your device throughout and nothing is transmitted to a server.

Worked example: a 4000 by 3000 photo down to 1280 wide

Take a photograph straight from a camera at 4000 by 3000 pixels, a 4:3 image, saved as JPEG at roughly 5.2 MB.

With the ratio lock on, pressing the 1280 preset sets the width to 1280. The stored ratio is 4000 divided by 3000, or 1.3333, so the height becomes 1280 divided by 1.3333, which is 960. The result is 1280 by 960, still exactly 4:3.

Pixel count falls from 12,000,000 to 1,228,800, a reduction to roughly one tenth. File size does not fall by exactly the same proportion, because JPEG compression already exploited redundancy in the original, but a result in the region of a few hundred kilobytes at 85 percent quality is typical, and the before and after sizes are shown so you can read the actual figure rather than estimate it.

Switching the output format to WebP at the same quality usually produces a noticeably smaller file again for the same visual result. If you unlocked the ratio and set 1280 by 1280 instead, the 4:3 photograph would be squeezed horizontally into a square, visibly distorting faces and straight lines, which is why the lock is on by default.

Choosing dimensions, format and quality

Resize downwards wherever possible. Enlarging an image cannot recover detail that was never captured, so the tool warns you when the target exceeds the original size; the result will look soft. If you genuinely need a larger image, start from the highest-resolution original you have rather than upscaling a small one.

Pick the format to suit the content. JPEG is the right choice for photographs and is universally supported. WebP usually produces smaller files than JPEG at comparable quality and is now supported by every current browser, making it the better option for the web. PNG is lossless and preserves transparency, so it is the format for logos, screenshots, line art and anything with flat colour or an alpha channel, at the cost of a much larger file for photographic content.

On quality, 80 to 90 percent is the practical range for photographs. Below about 70 you see blocking around edges and in gradients. Above 95 the file grows quickly for little visible gain.

Two caveats. Animated GIFs load, but the canvas captures one frame, so the output is a still image. Re-encoding a JPEG also loses a little quality each time, so repeated resize cycles degrade it.

Frequently Asked Questions

Leave the aspect-ratio lock enabled, which is the default. Type a target width and the height is calculated automatically from the original proportions, so the image scales without distortion. Unlock the ratio only when you deliberately need specific dimensions and accept that the picture will be squeezed or stretched to fit.
No. The file is decoded and redrawn on an HTML canvas inside the page, then encoded back to a blob you download directly. The image never leaves your device, which means the tool also works offline once the page has loaded and is safe to use with private or confidential pictures.
JPEG for photographs where maximum compatibility matters, WebP for the web since it is typically smaller at the same quality, and PNG for screenshots, logos, line art or anything needing transparency. The tool preselects a format matching your input file, so PNG sources stay lossless unless you change it.
You can set dimensions larger than the original, but a warning appears because enlarging cannot add detail that was not in the source; the result looks soft and slightly blurred. Where a larger version is genuinely needed, start from a higher-resolution original rather than scaling up a small one.
Between 80 and 90 percent suits most photographs. Below roughly 70 percent, compression artefacts become visible as blocking around sharp edges and banding in gradients. Above 95 percent the file size climbs steeply while the visible improvement is negligible. The slider is hidden for PNG output because PNG is lossless.