One-line answer
HEIF is the container format. HEIC is what people call a HEIF file whose image data is compressed with HEVC. Almost every .heic file from an iPhone is a HEIF file in this sense, so for everyday purposes the two names refer to the same thing.
What HEIF specifies
The HEIF technical overview from Nokia describes HEIF as ISO/IEC 23008-12. It defines how to store individual images, image sequences and their metadata in a file built on the ISO Base Media File Format (ISO/IEC 14496-12), the same family of box-structured files used for MP4 video.
The page makes several design points worth knowing:
- Still images are stored as items, and each image item is independently coded.
- Image sequences are stored as tracks, which may be used when images depend on one another.
- A file can hold many images, plus properties such as rotation and cropping, and auxiliary images such as a transparency plane.
- HEIF is a structural format from which codec-specific formats are derived. It includes provisions for HEVC, VVC, AVC and JPEG.
So the container says how things are arranged, and the codec says how pixels are compressed.
Where HEIC fits
HEIC is the label for the HEVC flavour. The libheif README says HEIC and AVIF are file formats employing HEVC (H.265) or AV1 image coding respectively. It lists, among the formats it supports, HEIC, AVIF, VVC, AVC, JPEG inside HEIF, JPEG 2000 and uncompressed data, and names libde265 as the default HEIC decoder.
That has a practical consequence: a file ending in .heif can contain a codec other than HEVC. The AVIF specification is explicit that it defines storage of AV1 images in the generic HEIF format. So AVIF is also a HEIF-family file, but it does not decode with an HEVC decoder.
Extensions you will meet
.heic: the extension iPhones use for HEVC images. Apple’s page on HEIF and HEVC media calls the photo format HEIF..heif: the generic container extension, used by some cameras and tools..avif: the usual extension for AV1 images in the same container family. Extensions are only labels, so FromHEIC detects the real type from file content instead of trusting them.
Because a name can mislead, the safest check is to look inside. The file checker reports the true type, codec, dimensions and image count, and the HEIC inspector shows brands, the primary item, grids and tiles, thumbnails and colour profiles.
Why it matters when something fails
If software opens .heic but not a .heif from another source, the usual cause is the codec inside, not the container. libde265 is an open implementation of the H.265 decoder, which is what an HEVC-in-HEIF reader needs. A reader built only for AV1 content will not handle it, and the reverse is also true.
The health check is built for this situation. It looks for a wrong extension, an invalid container, or an unsupported codec such as AV1 or JPEG inside HEIF, and then tries a real decode. The HEIF structure viewer goes down a level and shows the box tree with offsets and sizes, which is useful when you are debugging a damaged file.
Which name should you use
- When writing for users, say HEIC if the photo came from an iPhone.
- When writing a technical note, say HEIF for the container and name the codec: “HEIF with HEVC”.
- When naming files for upload, check what the destination accepts. Many forms list JPG or PNG only. See preparing photos for forms.
For background on why the format exists and where it is supported, start with what is HEIC. If you are choosing a web format instead, HEIC vs WebP and AVIF covers the AVIF side.