Step-by-step instructions
- 1
ImageMagick (command line)
Convert: `magick input.webp output.avif`. Quality: `magick input.webp -quality 60 output.avif`. Batch: `for f in *.webp; do magick "$f" "${f%.webp}.avif"; done`. Install: `brew install imagemagick` (Mac) or `sudo apt install imagemagick` (Ubuntu).
Go to converter - 2
avifenc (reference encoder, best compression)
avifenc needs PNG input: `magick input.webp /tmp/tmp.png && avifenc --min 24 --max 36 /tmp/tmp.png output.avif`. Install: `brew install libavif` (Mac) or `sudo apt install libavif-bin` (Ubuntu). avifenc produces the best AVIF quality for a given file size.
- 3
Sharp (Node.js, for build pipelines)
`npm install sharp`. Script: `const sharp = require('sharp'); sharp('input.webp').avif({ quality: 70 }).toFile('output.avif');`. Sharp uses libvips internally. For Next.js: the built-in `<Image>` component auto-serves AVIF to supporting browsers.
- 4
Squoosh (browser, no install)
Go to squoosh.app and open the WebP file. In the right panel, select AVIF. Use the quality slider. The side-by-side preview shows quality differences. Download the AVIF. Encodes in the browser using WebAssembly.
Why convert WebP to AVIF?
WebP was Google's answer to JPEG in 2010. AVIF is the industry's answer to WebP in 2019. Each generation compresses 20-30% better.
Your files never leave your device
FormatDrop runs the conversion engine entirely inside your browser using WebAssembly. No file upload. No server. Nothing stored. You can verify this by opening DevTools → Network tab and watching: zero upload requests.
Frequently asked questions
Is AVIF widely supported enough to replace WebP?
How much smaller will AVIF be compared to WebP?
Does WebP transparency convert to AVIF transparency?
No account. No upload. Works in any browser.