{"id":"image-heic","mimeType":"image/heic","name":"High Efficiency Image Container","shortName":"HEIC","category":"Photography","extensions":[".heic"],"description":"HEIC is Apple's variant of the HEIF (High Efficiency Image File Format) standard, which stores images and image sequences encoded with the HEVC (H.265) video codec. It offers significantly better compression than JPEG while natively supporting advanced computational photography features like 16-bit color, transparency, Live Photos, and depth maps.","seo":{"title":"image/heic MIME Type | Complete Developer Reference \u0026 Magic Bytes","description":"Complete reference for the image/heic MIME type: magic bytes, browser support matrix, HTTP headers, developer snippets, and technical specifications for HEIC.","faqs":[{"question":"What is the magic byte for HEIC?","answer":"HEIC uses the ISOBMFF container format. A typical HEIC file begins with a 4-byte box size, followed by the 'ftyp' box identifier, and then the 'heic' or 'heix' major brand. The hex representation is generally XX XX XX XX 66 74 79 70 68 65 69 63 (....ftypheic)."},{"question":"Is HEIC the same as HEIF?","answer":"Not exactly. HEIF is the overarching container format (which can hold various codecs), while HEIC specifically refers to a HEIF file where the image data is encoded using the HEVC (H.265) video codec."},{"question":"Do web browsers support HEIC?","answer":"Native support is very poor. Only Apple's Safari (on macOS High Sierra and iOS 11 or later) supports HEIC natively. Chrome, Firefox, and Edge do not support it due to licensing issues with the HEVC codec. Images must be converted to JPEG, WebP, or AVIF for the web."}]},"index":{"compression":["Lossy","Lossless"],"browserSupport":{"score":2,"label":"Poor (Safari Only)"},"commonUses":["iOS / iPhone Photography","macOS Ecosystem","High-Quality Image Archiving"]},"technical":{"magicBytes":{"hex":"XX XX XX XX 66 74 79 70 68 65 69 63","ascii":"....ftypheic"},"container":"HEIF / ISOBMFF","compressionAlgorithm":["HEVC (H.265)"],"colorDepth":["8-bit","10-bit","12-bit","16-bit"],"transparency":true,"animation":true,"metadata":{"exif":true,"xmp":true,"iccProfile":true},"alphaChannel":true,"progressiveLoading":false,"hdrSupport":true},"history":{"developer":"MPEG (Standard) / Apple (Adoption)","released":"2017","specification":"ISO/IEC 23008-12 (MPEG-H Part 12)"},"browserSupport":{"chrome":false,"chromeVersion":"None","firefox":false,"firefoxVersion":"None","safari":true,"safariVersion":"11+","edge":false,"edgeVersion":"None","internetExplorer":false},"softwareSupport":[{"name":"Apple Photos","logo":""},{"name":"Adobe Photoshop","logo":""},{"name":"GIMP","logo":"gimp.svg"},{"name":"ImageMagick","logo":"image-magic.webp"},{"name":"Windows Photos (with HEIF Extension)","logo":""}],"conversion":{"convertTo":["jpeg","png","webp","avif"],"convertFrom":["jpeg","png"]},"developer":{"httpHeaders":[{"header":"Content-Type","value":"image/heic"}],"htmlAccept":"image/heic, .heic","fileDetection":["Check for ISOBMFF 'ftyp' box at byte offset 4","Verify 'heic' or 'heix' brand string at byte offset 8"]},"prosCons":{"pros":["Exceptional compression efficiency — stores images at roughly half the file size of JPEG with equal or better visual quality","Natively supports modern photography features like depth maps, 16-bit color, HDR, and alpha channel transparency","Can store image bursts, focal stacks, and animations (Live Photos) within a single file"],"cons":["Heavily encumbered by software patents, leading to very poor adoption outside the Apple ecosystem","Not supported by standard web browsers (except Safari), requiring server-side or client-side conversion for web delivery","Windows requires downloading a separate (often paid) extension from the Microsoft Store to view natively"]},"specifications":{"url":"https://nokiatech.github.io/heif/","rfc":"","mimeAliases":["image/heif"]},"developerSnippets":{"python":"import magic\nprint(magic.from_file('photo.heic', mime=True)) # May output 'image/heic' or 'image/heif' depending on libmagic configuration","nodejs":"const FileType = require('file-type');\nconst type = await FileType.fromFile('photo.heic');\nconsole.log(type.mime); // image/heic","go":"import \"net/http\"\n\nmimeType := http.DetectContentType(fileBytes)\n// Standard Go net/http may default to application/octet-stream; use a specialized ISOBMFF/filetype library","php":"$mime = mime_content_type('photo.heic');\necho $mime; // Standard environments often require an updated magic.mime file to correctly identify HEIC"},"relatedFormats":["heif","jpeg","avif","webp"]}
