How this image compressor works
Your browser can already decode and encode images, so this tool uses those built-in codecs instead of a server. Each file is decoded with createImageBitmap, drawn onto a canvas at the size you choose, and encoded again with canvas.toBlob in the format and quality you pick. Files never leave the tab, which makes the tool safe for client photos, unreleased designs and screenshots of internal systems.
Because the browser does the encoding, results depend slightly on the browser. Chromium-based browsers and Firefox can encode WebP; Safari currently cannot, so it offers JPEG and PNG. AVIF encoding through a canvas is not widely available, so the tool asks your browser at load time and shows the AVIF option only where it actually works rather than silently handing back a PNG.
