🗜️ Image Compressor
Shrink JPEG, PNG, WebP and AVIF images with a live before/after preview. Runs entirely in your browser — your image is never uploaded.
About the Image Compressor
This tool re-encodes an image at a quality level you control and shows you the result next to the original before you commit to it. Everything — decoding, re-encoding, the preview — happens inside your browser using the Canvas API. The image is never uploaded, which is a claim worth checking rather than trusting: open your browser's network panel and watch nothing leave.
Compression here means two levers. Quality trades file size against visual fidelity in lossy formats (JPEG, WebP, AVIF). Format changes the codec doing the compressing: WebP typically beats JPEG by 25–35% at the same visual quality, and AVIF beats WebP where the browser can encode it. The before/after slider exists because the only honest answer to "how low can I go?" is your own eyes on your own image.
How to use it
- Drop an image (or click to pick one) — PNG, JPEG, WebP, AVIF or GIF up to 20 MB.
- Pick an output format. WebP is the usual best answer for photos.
- Drag the quality slider and watch the size verdict update live.
- Sweep the before/after divider across detailed areas to check for artefacts.
- Download — the filename keeps your original name with the new extension.
Frequently Asked Questions
Does this upload my image to a server?
No. The image is decoded, re-encoded and previewed entirely inside your browser using the Canvas API. You can verify this in your browser's network panel: after the page loads, no request carries your image anywhere. That is also why there is no file-size meter counting against a plan — there is no server doing the work.
Which output format should I choose?
For photographs, WebP at quality 75–85 is usually 25–35% smaller than an equivalent JPEG, and AVIF smaller still where your browser supports encoding it. For screenshots, diagrams and anything with sharp edges or text, PNG stays crisp; WebP handles those well too. JPEG remains the safe choice when the file must open absolutely anywhere, including very old software.
Why did my file get BIGGER after compressing?
The original was already well optimised — often by the tool that produced it. Re-encoding cannot always beat a good previous encode, especially at high quality settings or when converting a small graphic from PNG to a lossy format. The tool tells you when this happens instead of handing you a worse file; keep the original in that case.
Is quality 80 always safe?
For most photos, quality 75–85 is visually indistinguishable from the original at normal viewing sizes — that range is where the big savings live. Use the before/after slider to check areas with fine texture, gradients (skies!) and text. Banding in a gradient is usually the first artefact to appear.
What happens to the EXIF metadata in my photo?
Re-encoding through a canvas drops all metadata: EXIF camera settings, GPS location, colour profiles and thumbnails. For a file you are about to publish, that is usually what you want — smaller and more private. If you need to inspect what was in there first, use the EXIF Viewer tool.
Can I compress an animated GIF?
Only its first frame — the Canvas API decodes a single frame, so animation is not preserved. The tool warns you when it detects a GIF. For animated content, converting to a video format (MP4/WebM) with a desktop tool is the real size win anyway.