Image Compressor
Shrink images in your browser — you control the quality.
Your files never leave your device. No upload. No sign-up.
Drop an image here, or click to upload
JPG, PNG, or WebP — up to ~20 MB
Drop in a JPEG, PNG, or WebP and this image compressor re-encodes it at a quality level you choose, showing the file-size reduction before you download. Compression happens in your browser: the image is decoded, drawn to a canvas, and re-encoded via canvas.toBlob() at your chosen quality (0-1). Typical results: JPEG at quality 0.8 saves 40-70% with no visible loss; PNG converted to WebP saves 25-35%; product photos routinely drop from 4 MB to under 500 KB. Nothing leaves your device — the file that downloads never left the tab.
About the Image Compressor
Compress JPG, PNG, and WebP images right in your browser. Adjust the quality, preview the result side-by-side, and download a smaller file — all without uploading your photo to any server.
How to use the Image Compressor
- 1Drag and drop your image, or click to choose a file from your device.
- 2Adjust the quality slider to balance file size and visual fidelity.
- 3Compare the original and compressed versions side by side.
- 4Click “Download” to save the smaller, optimized image.
Why use our Image Compressor
Zero uploads
Compression runs locally with the Canvas API — your image never leaves your browser.
Adjustable quality
Fine-tune compression from 10% to 100% to hit your exact size target.
Instant side-by-side preview
See the original and compressed images and savings percentage at a glance.
Supports common formats
Works with JPG, PNG, and WebP source images up to ~20 MB.
How the compression actually works
The canvas API exposes toBlob(callback, mimeType, quality). For JPEG and WebP the quality argument is a hint between 0 and 1 that the browser maps to its internal quantisation tables — JPEG uses standard tables described in ITU-T T.81 (the 1992 spec), and each browser tunes the mapping slightly. PNG ignores the quality argument because it's a lossless codec; converting a PNG to a smaller PNG on this tool won't reduce size much — for that use pngquant or oxipng offline. Because a canvas has no compression history, re-encoding a JPEG here starts from decompressed pixel data and encodes once, so you don't accumulate generation loss beyond that single re-encode step. The tool never re-encodes an image twice inside a session.
When compression actually pays off
Every image on a web page adds to Largest Contentful Paint, one of Google's Core Web Vitals. Pages that pass Core Web Vitals rank measurably better in Search, so shrinking images from 3 MB to 300 KB has an SEO return, not only a bandwidth one. Ecommerce sites see a Shopify-reported ~7% conversion lift for every 100 ms of load-time improvement. Email attachments still get bounced above 25 MB (Gmail, Outlook), so a batch of holiday photos usually needs compression to send. Notion, Confluence, and Slack all cache images but display faster when the source is smaller. On mobile networks abroad, a 5 MB photo can cost a real dollar to send; compressing to 500 KB is a 90% saving on data.
Common mistakes and limitations
Compression can make files bigger, not smaller — if you re-encode a photo that has already been aggressively compressed by WhatsApp, the output at quality 0.9 may exceed the input. Drop the quality slider or accept the size increase; the tool shows both numbers before download. JPEG has no alpha channel, so converting a transparent PNG to JPEG flattens transparency to white; export as WebP to keep alpha and still get lossy compression. Quality below 0.5 introduces visible 8×8 block artefacts around high-contrast edges (a well-known DCT limitation). Metadata (EXIF, ICC colour profile) is stripped by canvas encoding, which usually helps privacy but can shift colours on wide-gamut displays that relied on an embedded Display P3 profile. Finally, the tool caps files at 100 MB to prevent mobile out-of-memory failures.
Image format comparison for the web (2026)
| Format | Compression | Alpha | Animation | Browser support | Best for |
|---|---|---|---|---|---|
| JPEG | Lossy | No | No | Universal (since 1992) | Photographs |
| PNG | Lossless | Yes | No | Universal | Screenshots, logos, line art |
| WebP | Lossy + lossless | Yes | Yes | 97% (all modern browsers) | General-purpose web images |
| AVIF | Lossy + lossless | Yes | Yes | 94% (Safari 16+, Firefox 93+, Chrome 85+) | Highest efficiency web |
| GIF | Lossless (256 colours) | 1-bit | Yes | Universal | Legacy animations |
| HEIC | Lossy | Yes | No | Safari only (iPhone native) | iPhone camera roll |
Support percentages from caniuse.com global usage, 2026 baseline.
Frequently asked questions
How much can I compress without visible loss?+
For photos, JPEG or WebP at quality 0.75-0.85 typically saves 40-70% of file size with no visible difference on a standard display. Below 0.6 you start seeing edge artefacts; below 0.4 the artefacts are obvious.
Can I compress multiple images at once?+
This tool compresses one file at a time so you can preview each result. For batch work of hundreds of files, a build-time tool like imagemin, Squoosh CLI, or sharp is a better fit.
What quality level should I use?+
Start at 0.8. For hero images and product photography, 0.85 preserves a bit more edge detail. For thumbnails and lazy-loaded gallery images below the fold, 0.7 is often invisible and saves another 15-20%.
Why did my file get bigger after compression?+
Because the original was already compressed (often by a chat app or CDN) and your chosen quality is higher than the source. The canvas has no idea what quality the input was — it just re-encodes at what you asked for. Lower the quality slider until the output is smaller.
Is metadata (EXIF, GPS, ICC profile) preserved?+
No. The canvas API strips all metadata. This is often good for privacy — GPS location tags are removed — but can shift colours on wide-gamut monitors that relied on an embedded Display P3 profile.
Should I use WebP or JPEG in 2026?+
WebP for anywhere you control the platform — it's supported by 97% of browsers per caniuse.com and produces ~25-35% smaller files than JPEG at equivalent quality. Stick with JPEG for email attachments, print handoff, or anywhere the recipient might be on legacy software.
Can I compress PNGs losslessly here?+
Not meaningfully. Canvas re-encoding a PNG produces a PNG that's usually similar in size. For real lossless PNG compression use pngquant (for palette reduction, which is technically lossy) or oxipng (truly lossless) offline.
What's the maximum file size?+
100 MB per file. Above that limit mobile browsers regularly fail with out-of-memory errors; the cap keeps the tool reliable on phones.
Does this remove EXIF GPS location data?+
Yes. Canvas re-encoding removes every EXIF field, including GPS coordinates. If you don't want to compress but do want to strip location, re-encode at quality 0.95 — you'll lose the metadata with negligible size change.
How does the tool compare to TinyPNG or Squoosh?+
TinyPNG uses a proprietary server-side palette reduction and typically beats browser encoding by a small margin on PNGs. Squoosh runs the same MozJPEG and libwebp codecs in WebAssembly and can produce marginally smaller files at the same visual quality. This tool trades that last few percent for zero-upload, zero-setup convenience.
Last updated: