Demystifying HEIC and HEIF files

If you are the proud owner of a last generation camera from Canon or Sony, you may have come across a curious new file type. The old standards are still there, including RAW and JPEG, but you may have also noticed a file choice called HEIC or HEIF. These are both acronyms for the same file type. HEIF stands for (high efficiency image file format) and HEIC stands for (high efficiency image codec). Regardless of what acronym you come across, they both refer to the same thing. It’s a high compression image format based on MPEG compression technology. MPEG is a compression algorithm created to make video files smaller while maintaining high quality. In 2015, MPEG technology was used to create HEIF files. It was intended to be a replacement for the the already aging standard JPEG, which was created way back in 1992; making it 30 years old now.

So is HEIF better than JPEG? The short answer is “yes”. HEIF surpasses JPEG in pretty much every way. The most important aspect of which is color. In the image world, we equate this to bit depth. JPEG is limited to 8 bit color (256 colors per channel). 256 shades of red, blue, and green resulting in 16.7 million total colors. HEIF boasts 16 bit color, which is not just twice the number of 8 bit, but rather over 16 million times. 16 bit color boasts 65,536 colors per channel resulting in over 281 trillion possible colors. And before you ask the question, “Is 281 trillion colors more than you’ll ever need?” Yes. Yes, it is. After all, high end video shows little to no artifacts when using just 10 bit color and certainly by the time it reaches 12 bit. The truth is most modern cameras only capture 12 to 14 bit color anyway; which simply means that HEIF is already somewhat future proof. HEIF also boasts more accurate color in that it is capable of being recorded in more accurate chroma subsampling.

I’m going to leave the specifics about chroma subsampling for another time since it could easily merit an entire blog unto itself. For now, just know that if you should be given the choice between 4:2:0 and 4:2:2, as you do with the Sony A7IV; the latter is the choice that has a higher potential for color accuracy. This also applies when faced with this same choice in video settings.

So when is 8 bit not enough? You may be saying at this point that you’ve used JPEGs for years without exposing it’s limitations; so why switch? An example of when 8 bit tends to fall apart is when you shoot a sky that transitions from very light blue to very dark. Below is a sample that shows what you may come across when editing an image with such a sky. The top image represents the “banding” or visible separations that can occur when you are limited to 8 bit color.

The amazing thing about HEIF is that the compression is so efficient, you get all those extra colors at no cost to file size. In fact, HEIF files tend to be roughly half the size of similar resolution JPEGs. Smaller but with much more information!

So, given that HEIF files boast more colors in a smaller file size, why has it not completely replaced JPEG? My best answer is that the world is just very slow to change. In fact, the vast majority of programs out there still don’t support or recognize HEIF files.

If you’re still wondering if you should switch to HEIF, then I would answer that question this way. Give HEIF a shot and if it fits into your workflow, then make the change. As of now, too many of the programs I like to use in my normal workflow do not yet support HEIF, so I’m pretty much stuck with RAW, JPEG and DNG. I would love to start using HEIF as soon as possible so I really hope the imaging world catches up.

P.S. For you Canon shooters wanting to give HEIF a try, it’s a little hidden. Take a look at the image below; set HDR PQ Settings to “on” to shoot in HEIF instead of JPEG.