Skip to main content

Convert HEIC images to JPG

Published: 2018-12-06 | Lastmod: 2019-05-08

My wife needed to upload a couple hundred pictures, from her Mac, to an online service that makes photo albums. The service didn’t accept images with the .heic extension, so she needed to convert them to .jpg. This would take many hours to do one-by-one, so thankfully ImageMagick supports conversion of HEIC images. Here’s how to do it.

Install Homebrew #

First, install Homebrew, which is a popular package manager for Mac.

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Install ImageMagick #

Next, install ImageMagick from Homebrew. The --with-libheif option tells Homebrew to compile with HEIF support, which allows it to handle .heic images.

brew install --with-libheif imagemagick

Convert the images from HEIC to JPG #

Finally, convert your images. This command will leave the original .heic image, then make a new .jpg image with the same name.

mogrify -format jpg *.heic

Delete original HEIC images #

Optionally, delete the original .heic images.

rm *.heic