Lean Image
Open menu

Converting a PNG to HEIC

There are two answers here and the second one matters more. Nothing running in a browser can write a HEIC, because HEVC encoding is patent-licensed and no free encoder exists to ship. But a PNG is usually a screenshot, a logo or an export from a design tool — and HEIC is a photo format built out of a video codec, which makes it bad at exactly the flat colour and hard edges a PNG tends to be full of.

Loading the optimizer…

Nothing is uploaded. Every image stays in this browser tab —here is how that works.

We cannot write it, and that is the smaller problem

The short version of the blocker: HEIC stores HEVC-encoded frames, HEVC encoding is licensed by patent pools that charge per unit, and there is no free encoder for a browser to load. The library this site uses to read HEIC files decodes only, and that is not going to change.

But you would probably not want the result even if the button existed, and that is the more useful thing to know. Almost every PNG that arrives at a page like this is not a photograph, and HEIC is a format designed for nothing else.

What a HEIC is built to hold

HEVC’s compression is a set of bets about what a camera sensor produces. It assumes each block of the picture resembles the blocks next to it, so it can predict one from another and store only the difference. It assumes fine variation everywhere, so it can throw away high-frequency detail your eye will not miss. And it usually assumes colour can be stored at half the resolution of brightness, because in a photograph nobody notices.

Every one of those bets is wrong about a screenshot. A hard edge between white and black is the opposite of a gradual prediction, and the encoder pays for it in ringing — a faint halo along the boundary, which is what makes small text look smeared. Half-resolution colour is worse still: it is why coloured text and thin coloured lines fringe and bleed through a photographic codec.

None of that is a flaw in HEIC. It is a photo format doing what a photo format does, to an image that is not a photo.

What your PNG probably is

Run through the likely cases:

  • A screenshot, a UI export, a diagram or a chart. Keep it as PNG, or compress the PNG by reducing its dimensions. If it is going on a website and a lossy step is acceptable, PNG to WebP is the usual answer.
  • A logo or an icon with transparency. PNG if it must stay exact, PNG to WebP for the web. If it started life as a vector, go back to the vector — a PNG of a logo is already a lossy copy in the sense that matters.
  • A photograph somebody saved as a PNG. This is the case where the format really is costing you, often ten times over, and it is the one HEIC was designed for.

Only the third of those has anything to gain from a photographic codec, and for that one there is a codec you can actually use.

If it is a photograph after all

AVIF is the closest thing to HEIC that exists outside Apple’s licensing: the same idea — a modern video codec’s intra-frame coding applied to a still — built on AV1, which is royalty-free, which is why every browser ships it.

You get similar file sizes to HEIC, real transparency with soft edges intact, wide colour, and high dynamic range if the source has any — plus a file that opens on Windows and Android, which HEIC does not. The one cost is encoding time: a large photograph takes several seconds, because a video encoder is doing the work. The tool at the top of this page is set to AVIF for that reason.

If you genuinely need a .heic

Apple’s encoder is the only one licensed to produce them at consumer scale, and there are two routes into it. Settings › Camera › Formats › High Efficiency on an iPhone or iPad makes the camera write HEIC directly, which is the right fix if what you want is HEIC files going forward. For a file you already have, Preview › File › Export on a Mac offers HEIF, and Photos will export HEIC from a library.

Worth checking first, though, whether the thing asking for a HEIC really needs one. It is very often an upload form listing HEIC among several accepted types, and one of the others is a format you already have.

Questions people ask about this conversion

Why is HEIC bad for screenshots?

Because it is a video codec working on a still. HEVC divides the picture into blocks and predicts each one from its neighbours, which suits the gradual variation of a photograph and fights the hard black-on-white boundary of a line of text. You get ringing around type and softened hairlines — the same artefacts a low-quality JPEG produces, for the same underlying reason.

What should a screenshot be instead?

PNG, if every pixel has to survive intact — which for a bug report, a document or anything with small type it usually does. If you want it smaller and it is going on the web, WebP or AVIF will reach sizes PNG cannot, at the cost of a lossy step that on flat colour is far less damaging than it sounds provided you keep the quality high.

Does HEIC support transparency?

It does, and support for it outside Apple’s own applications is thin enough that relying on it is a poor bet. If the transparency is why you are converting, PNG keeps it exactly and AVIF keeps it at a fraction of the size — and both are read by every current browser rather than one company’s.

What if my PNG really is a photograph?

Then AVIF, which is what the tool on this page is already set to. It is the same generation of compression technology as HEIC — built on AV1 rather than HEVC — reaches comparable sizes, carries wide colour and high dynamic range, and opens everywhere current instead of only on Apple devices.

How do I get a HEIC if I actually need one?

From Apple hardware. Settings › Camera › Formats › High Efficiency makes an iPhone or iPad write HEIC straight out of the camera, and on a Mac both Preview and Photos can export one from a file you already have. Those run Apple’s licensed encoder, which is the piece no web page can have.

Related

Other things you can turn a PNG into

Try it with your own file

Drop an image in and see the result before you download anything.