Convert PNG to AVIF

Converting PNG to AVIF produces the smallest widely supported image on the web today, transparency included — commonly half the size of the PNG on a photograph, though flat interface graphics can go the other way. Drop a folder above: everything converts on your own machine and comes back as a ZIP.

  • Where it runs In your browser. The file is never uploaded.
  • Lossy Some detail is traded for size. AVIF cannot hold everything a PNG can.
  • File size limit Up to 100 MB per file, free, without an account.

Up to 100 files at once. Mixed formats are fine.

What PNG to AVIF actually does

A generated landscape with a low sun and three ridges, used to show what JPEG does to continuous tone. Shown as PNG.

PNG139 KB

A generated landscape with a low sun and three ridges, used to show what JPEG does to continuous tone. Shown as AVIF.

AVIF17 KB8.1× smaller

A photographic scene — smooth gradients, soft edges, grain. This is the case AVIF is designed for or against, and the figures show which. Both images are drawn in code and encoded by the same converter that runs on this page, so the sizes are this site's own output.
A generated badge: a circular gradient on a transparent background with a white bar across it, used to show what each format does with transparency and with hundreds of shades. Shown as PNG.

PNG7 KB

A generated badge: a circular gradient on a transparent background with a white bar across it, used to show what each format does with transparency and with hundreds of shades. Shown as AVIF.

AVIF3 KB2.0× smaller

A transparent background and a gradient across the shape. AVIF either keeps both, keeps one, or fills the transparency with a solid colour — which is the difference that catches people out. Both images are drawn in code and encoded by the same converter that runs on this page, so the sizes are this site's own output.
A generated application window with a sidebar, a table and a bar chart, used to show what JPEG does to flat colour and hard edges. Shown as PNG.

PNG3 KB

A generated application window with a sidebar, a table and a bar chart, used to show what JPEG does to flat colour and hard edges. Shown as AVIF.

AVIF5 KB95% larger

Flat colour and hard edges, as in an interface, a chart or a logo. Very different behaviour from the photograph above, and the reason the answer is "it depends what is in the file". Both images are drawn in code and encoded by the same converter that runs on this page, so the sizes are this site's own output.

What AVIF buys you over PNG

PNG is exact and expensive. It never discards a pixel, which is why it is the right format for a logo or a screenshot, and it is why a page carrying twenty of them is heavy enough for a performance report to complain about.

AVIF attacks that from the other direction. It descends from a modern video codec, and it applies that machinery to a single frame — which is why it commonly lands at half the size of the PNG or better for a photograph, keeps a real alpha channel, and still looks the same at normal viewing size. On a page of product images, that is the difference between a slow first impression and a fast one.

AVIF or WebP: an honest comparison

Most people arriving here already moved to WebP and are wondering whether the next step is worth it. On photographs it usually is: at comparable quality AVIF tends to come in another twenty to thirty per cent below WebP, and it handles gradients and smooth skies with noticeably less banding.

On the other half of the web the answer flips. Flat interface graphics, icons, charts and screenshots — the things PNG was actually designed for — compress so well already that AVIF sometimes produces a larger file than WebP. Convert five representative images of your own and compare the byte counts. It takes ten minutes and it beats any general rule, including this one.

Encoding is slow, and that is the trade

AVIF encoding does far more work than PNG or WebP encoding. It searches much harder for structure it can describe compactly, and that search takes time — expect a noticeable pause per file, and several seconds for a large photograph, even on a fast machine.

The cost is paid once, on your computer, at the moment of conversion. Every visitor afterwards downloads a smaller file. That is a good bargain for site assets and a poor one for something you need converted right now, which is worth remembering when you drop two hundred files and go to make coffee.

Transparency comes across untouched

AVIF carries a proper alpha channel, so the transparency that forced the image to be a PNG in the first place is not a reason to stay. A cut-out product shot, an icon with rounded corners, a logo that has to sit on any background colour — all convert with no fill colour to pick and no halo around the edges.

This is the main practical difference from converting to JPG, where transparency has to be thrown away and replaced with something, and it is why AVIF can replace PNG across a whole asset folder rather than only in the photographic parts of it.

Quality settings, and where to leave them

The default sits at a level where the difference from the PNG is invisible at normal viewing size while the file is a fraction of the size. For photographs, screenshots and general site imagery, leave it there.

Raise it towards the top for images that will be zoomed into, or that carry fine text or thin one-pixel lines, where aggressive compression is easiest to spot. Lower it for large decorative backgrounds nobody inspects closely. The one thing to avoid is treating the converted file as the master — keep the PNG, because quality that has been given up cannot be recovered by converting back.

Where AVIF still fails, and it is not the browser

Browser support has not been the problem for years: Chrome, Edge, Firefox, Safari and the mobile browsers all display AVIF. If the image is going onto a web page, it will be seen.

The failures are elsewhere. Desktop image viewers, older phone galleries, chat applications, email clients and plenty of content-management upload forms still do not recognise the format. Do not email someone an AVIF and do not use it as the file a customer downloads — for that, send the JPG or the PNG. AVIF is a delivery format for web pages, not a general-purpose one.

Serving AVIF without leaving anyone behind

The standard pattern is a picture element with several sources: AVIF first, WebP second, and the original PNG or JPG as the img fallback. Each browser takes the first format it understands and everyone gets a working image, so nothing has to be decided on the visitor’s behalf.

This only works if you keep the originals. Convert a copy of your asset folder rather than converting it in place, and keep the PNGs in version control — they are the source the next format will be generated from too, whenever it arrives.

Converting an asset folder in one pass

Drop the whole directory. Each file converts in turn on your own machine with its own progress, keeps its filename with the extension swapped, and everything comes back as a single ZIP ready to drop into the build.

Because nothing is uploaded there is no queue, no per-file wait and no daily allowance — which matters more here than on most conversions, since AVIF encoding is the slow part and a hosted service would be charging you for that time on someone else’s processor.

How to convert PNG images to AVIF in bulk

  1. Drop your PNG files onto this page — an entire folder works.
  2. Leave the quality where it is, or raise it for images with fine detail.
  3. Take the AVIF files individually or as one ZIP.

PNG against AVIF: what the smaller file costs

PNG compared with AVIF
PNGAVIF
Full namePortable Network GraphicsAV1 Image File Format
File extension.png.avif
Media typeimage/pngimage/avif
CompressionLossless — nothing is discardedEither, depending on the setting
First published19962019
Published byPNG Development GroupAlliance for Open Media
SpecificationISO/IEC 15948AV1 Image File Format
LicensingOpen standardOpen standard
Standing todayCurrentCurrent
Bit depth1612
Colour it can describeRGB, greyscale, indexed paletteRGB, YCbCr, wide gamut
Largest image2,147,483,647 px per side65,536 px per side
Opens in a browserEvery browserCurrent browsers
Considered insteadWebP, SVG, JXLWebP, JXL, JPG

What is lost

PNG carries up to 16 bits per channel and AVIF stores 12. The extra precision is what survives heavy correction without banding, so the conversion is best made after the editing rather than before it.

What survives

Transparency survives. Both PNG and AVIF store an alpha channel, so a cut-out stays cut out and nothing is filled in behind it.

What the target format adds

AVIF can hold animation; a PNG is one frame. The result is a single-frame file in a format that could hold more.

Opening the result

Current browsers read AVIF; older ones do not. It is the less portable of the two, so it is worth being sure the program at the other end accepts it before sending one.

AVIF is a container rather than a single format. What actually plays is the codec inside it — usually AV1 — which is why two files with the same extension can behave differently on the same device.

GIMP reads both PNG and AVIF, so there is a way to check the result against the original without a second tool.

What each format is for

PNG is PNG Development Group's format, published in 1996. It records 16 bits per channel.

AVIF comes from Alliance for Open Media and dates from 2019, specified as AV1 Image File Format. GIMP, Squoosh and ImageMagick all read it.

PNG was published in 1996 and AVIF in 2019. The older one is generally the safer file to hand to somebody; the newer one usually does the job in fewer bytes.

PNG to AVIF: size, support and transparency

Are my PNG files uploaded anywhere?

No. This conversion runs entirely inside your browser, so the file never leaves your device. You can confirm it yourself: open the network tab of your browser's developer tools and convert something. You will see the page load, plus the analytics and advertising the site is paid for with — and nothing carrying your file. The engine behind this particular pair is jSquash, WebAssembly builds of the reference image codecs; your browser fetches it once and caches it.

Is AVIF actually smaller than WebP?

Usually, and by a meaningful margin on photographs — often another 20 to 30 per cent below a WebP of equivalent quality. On flat graphics, icons and screenshots the gap narrows and WebP sometimes wins outright, so it is worth converting a few real files and comparing rather than assuming.

Does AVIF keep transparency?

Yes, with a full alpha channel, exactly as PNG does. A cut-out logo or an image with soft transparent edges converts without any fill colour to choose.

Why does converting to AVIF take so long?

AVIF encoding is genuinely expensive — it comes from video compression and searches much harder for redundancy than PNG or WebP encoding does. A large photograph can take several seconds per file. That cost is paid once, by you, and every visitor afterwards downloads less.

Which browsers can display AVIF?

Chrome, Edge, Firefox, Safari and the mobile browsers have all supported it for years, so on the open web it is safe. Where it still fails is outside the browser: some desktop image viewers, older phone galleries, chat apps and email clients will not open an AVIF attachment.

Is converting PNG to AVIF lossless?

Not at the default setting — a small, generally invisible amount is given up in exchange for the size. Raising the quality control towards 100 keeps more, at the cost of a larger file. Keep the original PNG either way; it is the master copy.

Should I use AVIF or WebP for my site?

Serve both if you can — a picture element with an AVIF source, a WebP source and a PNG fallback lets each browser take the best it understands. If you only want one format, WebP is the safer single choice and AVIF the more aggressive one.

More about these formats

Where these figures come from

The claims this page makes about PNG and AVIF are checkable, and these are the documents that settle them.