JPG to AVIF converter

Squeeze JPG and PNG images into AVIF, the most compact format modern browsers display.

  • Processed on your device. Your photos are never uploaded. How we know
  • Free, no sign-up, no watermark

Drop JPG images to convert to AVIF

Drop files, paste with Ctrl+V, or choose them from your device.

JPGPNGWebPHEIC

PixWrench’s code runs on your device. We don’t receive your files, file names or their contents.

PixWrench’s code runs on your device. We don’t receive your files, file names or their contents. What happens to your files

How to use it

How to convert JPG to AVIF

AVIF stores still images using the AV1 video codec, and it is remarkably good at it. MDN cites lossy AVIF files as around half the size of comparable JPEGs. For a site with lots of photos, that is a real cut in what every visitor downloads.

The catch is effort. AVIF encoding is slow, especially on phones, and the output is meant for web pages rather than for sharing or editing. This page gives you the encoder, a speed control and honest numbers so you can decide when the savings are worth it.

  1. 1

    Add your images

    Choose JPGs or PNGs, including ones with transparent backgrounds. Bigger batches are fine but take a while.

  2. 2

    Set quality and speed

    Start at quality 55. Leave the speed setting where it is unless you want faster encodes or are willing to wait longer.

  3. 3

    Collect the AVIF files

    Download each finished image, or the full set as a zip, and add them to your site with a fallback for older browsers.

What this tool does

  • AVIF quality slider, starts at 55
  • Encoder speed control: faster or more thorough
  • Alpha transparency carried into the AVIF
  • Source files: JPG, PNG, WebP, HEIC or AVIF
  • Queue many images, collect a zip
  • libavif with the AOM encoder, in WebAssembly
Worked example

Worked example: one photo, three encoder speeds

We encoded our 1600 × 1200 test photo (a 398,618-byte JPG) with libavif and the AOM encoder at quality 55, in single-threaded Node on a desktop computer:

Encoder speedAVIF sizeTime
4 (slower)28,967 bytes23.5 s
626,823 bytes (−93%)1.5 s
8 (faster)28,793 bytes0.4 s

For comparison, the same pixels as a quality-90 JPG took 0.47 s and 219,965 bytes; as a quality-80 WebP, 102,892 bytes. Notice that the slowest setting did not give the smallest file here: at a fixed quality number, speed changes how hard the encoder searches, which shifts both size and detail. Compare results by eye, and expect a phone to be slower than these desktop timings. (1 KB = 1,000 bytes.)

Under the hood

What the AVIF encoder is doing

Your image is decoded in a Web Worker, then passed to libavif with the AOM AV1 encoder, compiled to WebAssembly. The encoder weighs many candidate ways of compressing each region of the picture and keeps the one that best meets the quality target. Trying more options is what makes it slow; the speed setting decides how many it tries.

The result is packaged in a HEIF container as the Alliance for Open Media specification defines, with an alpha plane when the source has transparency. EXIF metadata is not written into the AVIF output, so camera details and GPS location are left behind.

Compatibility

Browser support, and when not to use AVIF

MDN lists AVIF support from Chrome 85, Edge 121, Firefox 93 and Safari 16.1. MDN also recommends a fallback in WebP, JPEG or PNG using the <picture> element, since support has little historical depth. A typical setup lists AVIF first and a JPG last; browsers skip any source type they can’t show.

Skip AVIF for images people will download, edit or attach to messages; a JPG is friendlier there. MDN notes that AVIF doesn’t render progressively, so a large AVIF appears only once fully downloaded. When encode time is a problem, WebP conversion is much quicker and still well ahead of JPG. The format comparison guide weighs all four, and the web compression guide covers sizing.

Limits

Good to know

  • Encoding is slow on phones. Phones are slower than our desktop timings, so keep the tab open while a batch runs.
  • No EXIF in the output. Date taken, camera and location are not written into the AVIF files.
  • Quality numbers don’t match other formats. AVIF 55 is not comparable to JPG 55; judge the image, not the number.
  • Some software can’t open AVIF. Keep your JPG or PNG originals, and use AVIF to JPG if you need to go back.
  • Resize first. Encoding a 1600 px image for an 800 px slot wastes time and bytes; the resizer fixes that.
Privacy

What happens to your files

Processed on your device. Your photos are never uploaded. PixWrench’s code runs on your device. We don’t receive your files, file names or their contents.

AVIF encoding is heavy work, and all of it is done by your own processor in this browser tab. That is why it can be slow on a phone, and also why your images never need to leave it. The finished AVIF files go straight to your downloads; we see neither them nor their names.

Keep going

Related tools and guides

FAQ

Questions people ask

Is AVIF better than WebP?

For file size, often yes: in our test, quality-55 AVIF was about a quarter of the size of quality-80 WebP. WebP encodes much faster and has a longer support history.

Why does AVIF conversion take so long?

The AV1 encoder tests many ways of compressing each block. That search is what produces small files. The speed setting trades thoroughness for time.

Does AVIF support transparency?

Yes. Transparent PNGs keep their alpha channel in the AVIF output.

Which browsers can show AVIF images?

According to MDN: Chrome 85, Edge 121, Firefox 93, Safari 16.1 and later versions. Provide a JPG or WebP fallback for older ones.

Is my photo’s location saved in the AVIF?

No. EXIF metadata, including GPS, isn’t written into AVIF files made here.

What quality setting should I use?

Start with the default of 55 and compare against the original at full size. Raise it for detailed hero images; lower it for thumbnails.

Review

Sources and review