Get started
HomeImage ToolsImage Compressor
Image ToolsRuns in your browser · files never uploaded

Image Compressor

Shrink file size, keep quality

4.5· 40 votes
An image compressor reduces the byte size of a PNG, JPG or WebP image without visibly degrading quality. StuHub re-encodes images in-browser using modern mozJPEG and WebP encoders, typically saving 40–70% on JPG and 50–80% on WebP at "indistinguishable" quality.
Your file never leaves this browser. Everything runs on your device — no uploads, no server storage, no retention.How it works →
📉

Drop an image to compress

JPEG and WebP output · runs entirely in your browser

What is Image Compressor?

Shrink image file size without visibly affecting quality. The compressor uses modern JPG and WebP encoders, with a live quality slider and a split-view preview so you can see exactly where the trade-off sits. Typical savings are 40-70% on JPG and 50-80% on WebP at "indistinguishable" quality. Great for cutting page-weight on websites, email attachments under size limits, and WhatsApp or Slack sharing.

How do I use Image Compressor?

  1. Drop a JPG, PNG, or WEBP onto the upload zone.
  2. Choose an output format — WebP gives the smallest files; JPG is the most compatible.
  3. Drag the quality slider until the preview looks clean but the size has dropped.
  4. Click Download to save the smaller image.

Image Compressor by the numbers

Encoders
mozJPEG, sharp-webp
Typical JPG savings
40–70%
Typical WebP savings
50–80%
Formats out
PNG, JPG, WebP
Max input
50 MB

Common use cases for Image Compressor

  • Cutting hero-image page weight before deploying a Next.js site.
  • Compressing wedding-photo exports before sharing a gallery link.
  • Shrinking a marketplace product shot to fit a 1 MB upload cap.
  • Preparing forum-safe screenshots that do not re-host through the forum.
  • Batch-compressing an Instagram content pack before scheduling.

Common pitfalls and how to avoid them

  • File got bigger after compressionHappens when the source was already near-optimal. Switch output format (JPG → WebP) or keep the original.
  • Visible banding on gradientsPush quality up to 85% or switch to PNG-8/PNG-24 if the image has solid colours with few gradients.
  • Transparency vanishedJPG cannot store transparency. Output to WebP or PNG if the original had an alpha channel.

When should I use Image Compressor?

Use Image Compressor when size matters more than dimensions. If you need a specific width and height, use Image Resizer instead. For many files at once, use Bulk Resize, which also re-encodes as it resizes.

Frequently asked
How much smaller will my image get?

Typical JPG savings are 40–70% depending on quality setting. WebP usually saves another 20–30% on top of JPG at the same perceived quality.

Which format should I choose for web?

WebP offers the best size-to-quality ratio and is supported by every modern browser. Use JPG for maximum compatibility, PNG only if you need transparency.

Can I control the output size?

Yes — adjust the quality slider (10–100%) and set a maximum dimension. The preview updates live so you can dial in the trade-off.

Is my file uploaded anywhere?

No. Everything runs in your browser. Your files never leave your device, and there is no server component for this tool.

Related in Image Tools
Image Resizer
Image Converter
Image Cropper
Image Rotator
Image Flipper
DPI Changer
Watermark Adder
Background Remover