webby.tools

Image Compressor

Reduce the file size of your images without sacrificing quality. Supports JPG, PNG, WebP, GIF, and more. Upload multiple files and download them all at once — everything runs in your browser, nothing is ever uploaded to a server.

Upload Images to Compress

Drag and drop images here, or click to browse

Supports JPG, PNG, WebP, GIF — batch compress multiple files at once

How to Use

  1. Upload images — drag and drop or click to select one or more image files. JPG, PNG, WebP, and GIF are all supported.
  2. Choose settings — select an output format (or keep the same as input), drag the quality slider, and optionally set a max width and/or max height to resize images while compressing.
  3. Compress — click Compress All to process every file, or compress files individually using the button on each card.
  4. Download — save individual compressed files, or click Download All as ZIP to get everything at once.

The before/after file sizes are shown on each card so you can see exactly how much you saved.

Why Compress Images?

Image file size directly affects how fast web pages load. A page full of unoptimised photos can take several seconds to load on a mobile connection — and every extra second of load time reduces conversions, increases bounce rates, and hurts search engine rankings. Google's PageSpeed Insights and Core Web Vitals both measure how quickly images load and factor it into rankings.

For email, social media, and storage, smaller files also mean faster uploads, fewer errors hitting attachment limits, and less space used on your device or hosting account.

Which Format Should I Choose?

Format Best For Notes
JPG Photos, complex images Smallest files for photographs; no transparency
WebP Web images 25–35% smaller than JPG at same quality; wide browser support since 2020
PNG Screenshots, graphics, logos Lossless — no quality loss; larger files than JPG/WebP

For photos going on a website, WebP delivers the best compression. For maximum compatibility (email, older software, print), JPG is the safest choice. Use PNG when you need sharp edges, transparency, or a pixel-perfect lossless copy.

What Quality Setting Should I Use?

The quality slider controls how aggressively lossy compression is applied. Higher quality = larger file, less compression. Lower quality = smaller file, more visible artifacts.

Quality Typical Use
90–100% Archival, print — maximum fidelity
75–89% Standard web images — good quality, reasonable size
60–74% Compressed web thumbnails — noticeable only on close inspection
Below 60% Aggressive compression — visible artifacts; useful for very large images where size is critical

The default of 82% is a good starting point for most web images. Lower it if you need smaller files; raise it if you spot artifacts.

Max Width and Max Height

The max width and max height fields let you resize images at the same time as compressing them. Both fields are optional — you can set one, both, or neither.

When both are set, the image is scaled down to fit inside that box while preserving the original aspect ratio. The same logic as CSS object-fit: contain applies — whichever constraint is more restrictive wins, and the other dimension falls wherever it needs to in order to keep the proportions correct.

For example, if you have a 3000 × 2000px image and set max width to 1200 and max height to 900:

  • Fitting to max width alone would give 1200 × 800px — this fits within the 900px height limit, so this constraint wins.
  • Fitting to max height alone would give 1350 × 900px — this exceeds the 1200px width limit.
  • The result is 1200 × 800px.

If instead the image were 2000 × 3000px (portrait) with the same limits:

  • Fitting to max width alone would give 1200 × 1800px — this exceeds the 900px height limit.
  • Fitting to max height alone would give 600 × 900px — this fits within the 1200px width limit, so this constraint wins.
  • The result is 600 × 900px.

Images that are already smaller than both limits are never enlarged.

Resizing combined with compression is the most effective way to reduce file size — a 4000px wide photo brought down to 1200 × 800px at 82% quality typically produces a file 10–20× smaller than the original.

Frequently Asked Questions

Can I compress PNG files without losing quality?
When the output format is PNG, the quality slider has no effect — PNG is always lossless. PNG files are compressed using a lossless algorithm, so every pixel is preserved exactly. To reduce PNG file size with this tool, set the max width to resize the image. For further reduction, switch the output format to WebP or JPG, which use lossy compression.

Why is my compressed PNG bigger than the original?
PNG compression efficiency varies by image content. Re-encoding a PNG through a canvas element can sometimes produce a larger file than the original if the original was already heavily optimised with a specialised PNG encoder like pngquant. In this case, use WebP or JPG output for a smaller result.

Does this work on mobile?
Yes — the tool runs in your browser and works on any modern device including phones and tablets.

Are my images uploaded to a server?
No. All compression happens locally in your browser using the Canvas API. Your images never leave your device.

What's the maximum file size I can compress?
There's no enforced limit, but very large images (above 20–30 MB) may take a moment to process depending on your device's memory and processing power.

Can I compress animated GIFs?
GIF animation cannot be preserved when compressing through a canvas element — only the first frame is output. Use this tool for static GIFs. For animated GIFs, reduce frame count or use a dedicated GIF optimiser.

Why does JPG produce a slightly different image than the original?
JPG is a lossy format. Each encode discards some image data. The higher the quality setting, the closer the result is to the original — but there will always be a small difference at the pixel level. At 82%+ quality this difference is invisible in normal use.

Icons from Creative Fabrica

This website may contain affiliate links. If you click on an affiliate link and make a purchase, we may receive a small commission at no additional cost to you.