Convert JPG photos to AVIF without uploading them
AVIF is a modern image format based on the AV1 video codec. For the same visual quality it is usually far smaller than JPEG, so pages load faster and you store less. This tool re-encodes your JPG photos as AVIF using a quality slider you control, with no upload and no signup.
What makes AVIF smaller than JPEG?
JPEG was standardised in 1992 using a DCT (Discrete Cosine Transform) compression algorithm that divides the image into 8×8 pixel blocks. At lower quality settings those blocks become visible as the characteristic “blocky” or “blurry” JPEG artefact pattern. AVIF is derived from the AV1 video codec (2018) and uses more sophisticated compression techniques — larger and variable transform block sizes, better prediction modes, and more efficient entropy coding — that remove more redundant information before introducing perceptual artefacts. The practical result is that an AVIF at the same visual quality is meaningfully smaller.
A rough size comparison for photographic content at equivalent visual quality:
| Format | Relative file size |
|---|---|
| JPEG (baseline) | 100% |
| WebP | ~65–75% |
| AVIF | ~45–65% |
These are rough averages; the actual ratio depends on image content (photographic scenes compress better than flat graphics), quality settings, and the specific encoder. The tool shows the exact byte size after each conversion so you can compare directly.
How it works
Each JPG is decoded by the browser and drawn onto an HTML <canvas> at its original pixel dimensions. The canvas is then re-encoded with canvas.toBlob("image/avif", quality), where the quality slider (10%–100%, 60% by default) maps to the AVIF encoder’s quality setting. The result is offered as a downloadable .avif file showing its new byte size.
AVIF encoding requires a recent browser: Chrome 85+, Edge 85+, Firefox 93+, Safari 16+. If your browser cannot encode AVIF, the tool reports this rather than silently failing.
Quality slider guidance
| Quality | Typical use case |
|---|---|
| 10–30% | Thumbnails, previews, low-bandwidth delivery |
| 40–60% | General web photos; good default for most content |
| 70–85% | E-commerce product photos where detail matters |
| 90–100% | Hero images, photography portfolios; near-lossless |
The default 60% is a good starting point for most web images. Drop lower for images that will only ever be seen at small sizes on screen.
Browser support for displaying AVIF
All major browsers can display AVIF images. Older browsers (Internet Explorer, Safari before 16) cannot. If you need compatibility with older users, serve AVIF with a JPEG fallback using the HTML <picture> element:
<picture>
<source srcset="photo.avif" type="image/avif" />
<img src="photo.jpg" alt="…" />
</picture>
Everything runs locally in your browser — your photos are never uploaded, stored, or seen by anyone.