tools / image
image/
Compress, resize and convert images in bulk (JPG / PNG / WebP). Nothing is uploaded; everything runs in your browser.
Need an .ico icon? Use PNG to ICO to make a website favicon or Windows icon →
What is compressing images in the browser
Compressing images in the browser means decoding an image and re-encoding it at a new size and quality: JPG trades file size against a quality setting from 0.1 to 1, while PNG is lossless and has no quality setting. This page re-encodes images in batches on your device with the browser's canvas and outputs JPG, PNG or WebP, up to 200 MB in total.
How it works: decode, resize, re-encode
- The image is decoded with createImageBitmap and turned upright according to the orientation stored in the photo's EXIF; where the browser does not support that, an image element is used instead.
- The output size is worked out: by longest side, the longest side is at most the 1 to 16384 pixels you enter and images are only shrunk, never enlarged; by percentage, the size is multiplied by 1% to 400%; the result is rounded to whole pixels.
- The image is drawn onto a canvas, resized with the browser's high-quality interpolation; for JPG output a white background is laid down first, because JPG has no transparency channel.
- canvas.toBlob encodes to the target format. The HTML Standard says the quality argument is a number from 0.0 to 1.0 that only applies to formats with variable quality such as JPEG, so PNG is simply re-encoded once without loss and without reducing colours; if the browser cannot encode WebP, this page greys out the WebP button.
The whole process runs on your device, and images are not uploaded to any server.
Sources
FAQ
Why is the compressed image larger than the original?
Usually the original was already compressed tightly, or you converted a JPG to PNG. That row shows a notice and a "Download original" button, so you can simply keep the original. To try again, lower the quality or shrink the size under "Resize".
The quality slider is greyed out for PNG. How do I make a PNG smaller?
PNG is lossless and has no quality setting, so the slider is disabled when PNG is selected. To shrink the file, reduce the dimensions under "Resize". For photos, switching the output to JPG or WebP usually makes the file much smaller.
Can I compress an image to a specific size in KB?
No. There's no target-size option, only quality and resize. Every change reprocesses the images automatically and the new size is shown on each row, so adjust until it's small enough. For JPG and WebP, lower the quality first, then reduce the dimensions if that isn't enough.
What color does a transparent PNG get when converted to JPG?
White. JPG can't store transparency, so the image is placed on a white background first. To keep transparency, choose PNG or WebP as the output.
Which image formats are supported? Can I compress HEIC or AVIF?
It reads JPG, PNG, WebP, GIF (first frame only) and BMP, and outputs JPG, PNG or WebP. HEIC, AVIF, SVG and others aren't supported; adding one shows "is not a supported image format", so convert it to JPG first. If the WebP button is greyed out, your browser can't encode WebP, so use Chrome or Edge. WebP images can still be read.
How many images can I process at once? Is there a size limit?
There's no separate limit on the number of images, but the total size can't exceed 200 MB; files beyond that are skipped with a notice. Each output image can have at most 100 million pixels. For "Longest side" you can enter 1–16384 (it only shrinks, never enlarges), and "Percent" accepts 1–400.
Does "Download all" create a zip file?
No. The files are downloaded one by one, about 0.35 seconds apart. Your browser may ask whether to allow multiple downloads; click Allow. File names stay the same except for the new format's extension.
Does the compressed image keep EXIF data such as the shooting location?
No. The image is drawn onto a canvas and re-encoded, so EXIF data like capture time, location and camera model isn't carried over. Phone photos are rotated upright according to their EXIF orientation first, so they won't end up sideways.