85

So, here’s the thing. I have a new iPhone and an old Mac. iOS 11 (still in beta as of today) and El Capitan (no more updates for this Mac). I use iCloud photo library in both devices. When I take a photo in the new format with my iPhone 7, is there any way to use it right away in my mac, without having to convert it in my iPhone first? I mean, can I get those photos synced through iCloud and converted locally on my Mac?

I have tried to find a third party software that could do that kind of conversion, but was not able to find any that would work on El Capitan. Any idea?

pkamb
  • 7,183
  • 9
  • 60
  • 99
Victor Domingos
  • 1,042
  • 1
  • 7
  • 11
  • You should be able to convert HEIF photos on export. Have you tried that? – Allan Sep 01 '17 at 17:27
  • 1
    I am still trying to understand the mechanics of it. I have set it to Automatic in the iPhone. But I got a couple heic files in Photos app through iCloud Photo Library sync and also when downloading from iCloud website. I guess the website shout allow us to export a JPEG. And it would be nice to have the same in Photos app, in El Capitan. – Victor Domingos Sep 01 '17 at 17:31
  • I would like to start using the new format in order to save space, but still have some way to access my photos from my current Mac. – Victor Domingos Sep 01 '17 at 17:32
  • Well... Now I was able to download a JPG version of a HEIC photo from iCloud website. Not sure if I changed something in my settings since the last time I tried. But Photos app still reports the synced file (not the one I downloaded) as a .HEIC. And if I try to export it, it does not work. Only JPGs get exported. Which is weird, because the photo gets displayed normally in the photos app. – Victor Domingos Sep 01 '17 at 18:11
  • There is an app called Graphic Converter but it doesn't support these formats. You might want to keep an eye on it. – Ɱark Ƭ Sep 01 '17 at 18:12
  • 1
    @Mark yeah, that was one of my first thoughts, but it seems that their HEIC conversion is a feature that only works in a more recent OS. – Victor Domingos Sep 01 '17 at 18:16
  • Have you tried Image Capture? – IconDaemon Sep 01 '17 at 19:26
  • @IconDaemon I don’t think Image Capture can convert file types. It certainly cannot open image files already in the computer file system. Remember, my photo files are already stored in the computer, because I am using iCloud Photo Library. Also, I am using “Optimized Storage” in both devices, so the actual original image file is usually in iCloud server, not necessarily in one of my devices. – Victor Domingos Sep 02 '17 at 13:01
  • Strangely enough, i have now a few HEIC photos in my library, and when I try to download them from iCloud website, at least one of them comes out as a JPG, but most are downloaded as HEIC. I tryed that in at least three different Macs with El Capitan. What's the criteria for the server to decide if it will send us a JPG or a HEIC file? – Victor Domingos Sep 02 '17 at 13:35
  • The only way I was able to get a partial sollution for this problem, until now, was going to iCloud website, Photos, then select one of the photos and click the share link at the top (the square thing with an arrow pointing up). Then choose "email". It opens a popup window with the photo inside. At that time, you may drag that photo to your Desktop, and you'll get a JPG. It's not full resolution, but probably will do for web and other purposes that do not require a full-res image. – Victor Domingos Sep 02 '17 at 13:39
  • Now, another very strange issue is that the share button in the Photos web-app, in iCloud website, does not show up in every computer, even if all of them are using El Capitan... Shouldn't a feature like this the hardware independent? – Victor Domingos Sep 02 '17 at 13:46
  • @IconDaemon When importing photos with a cable, with Photos app or Image Capture, the HEIC photos show up and are imported as JPG files (I have set it to Automatic, in iPhone's preferences). It can be a workaround for recent photos, but still not a solution for photos that came through iCloud sync and that may not be locally available in iPhone anymore... – Victor Domingos Sep 03 '17 at 10:40
  • 11
    `sips -s format JPEG myfile.heic --out myfile.jpg` – Pat Niemeyer Jul 09 '18 at 03:04
  • And the multiple file version: `for i in *.HEIC; do sips -s format JPEG "${i}" --out "${i%HEIC}JPG"; done` (from https://robservatory.com/use-sips-to-quickly-easily-and-freely-convert-image-files/) – dmon Jan 27 '20 at 16:26
  • 1
    `sips` on El Capitan does not work for converting HEIC images. – TJ Luoma Feb 12 '20 at 11:05
  • 5
    @PatNiemeyer and @dmon that should be `sips -s format jpeg` with lowercase `jpeg`. Uppercase gives `Error: Unsupported output format JPEG` (sips-294 on MacOS Catalina 10.15.5) – jonatan Sep 27 '20 at 20:43
  • Try jpeg (lowercase) instead of JPEG (uppercased) in the sips command. Worked like that for me on macOS ventura. – Arda Dec 04 '22 at 07:20

8 Answers8

135

You can use the command line tool imagemagick to convert HEIC images to JPG.

# install imagemagick
brew install imagemagick

# convert a single image
magick convert foo.HEIC foo.jpg

# bulk convert multiple images
magick mogrify -monitor -format jpg *.HEIC
wisbucky
  • 4,588
  • 5
  • 30
  • 33
  • 2
    What does "convert: no decode delegate for this image format `HEIC" mean? – gap Mar 09 '19 at 22:16
  • 4
    @gap, you error message means you don't have the right stuff installed to deal with the HEIC format. `brew upgrade imagemagick` solved this problem for me. – kuzzooroo Apr 19 '19 at 19:11
  • 1
    @gap Not sure. My original install command had an extra option: `brew install imagemagick --with-libheif`, but others said it wasn't needed anymore. You could give that a try. Maybe it makes a difference depending on your OSX version. – wisbucky Apr 24 '19 at 18:04
  • @wisbucky, regarding my non-deleted answer: you were right. not sure what was going on before. Thanks for the feedback. – Kirby May 13 '19 at 23:05
  • Perfect! worked for me – Dimitrios Filippou Jun 09 '19 at 22:18
  • You need `libde265` to use HEIC with ImageMagick... https://stackoverflow.com/a/54558699/2836621 – Mark Setchell Feb 01 '20 at 14:48
58

The macOS-native way of doing image conversions like these is apparently sips(1) (raising comments of Pat Niemeyer and jonatan to proper answer status, for improved findability):

sips -s format jpeg myfile.heic --out myfile.jpg

So if you have a directory full of HEIC files, you can launch a macOS Big Sur terminal, where, if you run the default Zsh shell, you can make jpeg copies of all those files like this:

for i in *.heic(:r) ; sips -s format jpeg "$i.heic" --out "$i.jpg"

…and presto, you've got jpeg copies!

If you want to also nuke the originals, follow up with a rm *.heic – or use this variant instead:

for i in *.heic(:r) ; sips -s format jpeg "$i.heic" --out "$i.jpg" && rm "$1.heic"

…and integrating Josh Hibschman's tip to also retain timestamps:

find . -type f -iname '*.heic' | while read i do \
  fileNoExt="${i%.*}"; \
  jpgFile="${fileNoExt}_heic_conv.jpg"; \
  sips -s format jpeg "$i" --out "$jpgFile"; \
  touch -r "$i" "$jpgFile"; \
  rm "$i"; \
done
philshem
  • 89
  • 9
ecmanaut
  • 860
  • 8
  • 14
  • 15
    Without question this should be the definitive answer. No extra software to be installed, as simple as it can get. – Endareth Jul 14 '21 at 11:55
  • When I try this in `bash` I get `Warning: .heic not a valid file - skipping`. The `imagemagick` solution works for me. – Chris Redford Jul 22 '21 at 02:36
  • What does the `(:r)` qualifier do? – Kenneth Worden Aug 06 '21 at 00:11
  • 1
    `(:r)` is a zsh globbing filename generation feature that removes a filename extension from matches, so `*.heic(:r)` would match example files `a.heic` and `b.heic` as `a b`. – ecmanaut Aug 20 '21 at 00:42
  • 1
    Recommend adding `touch -r myfile.heic myfile.jpg` to copy over created and modified dates.. or altogether with renaming `find . -type f -iname '*.HEIC' | while read i do fileNoExt="${i%.*}"; jpgFile="${fileNoExt}_heic_conv.JPG"; sips -s format jpeg "$i" --out "$jpgFile"; touch -r "$i" "$jpgFile"; rm "$i"; done ` – Josh Hibschman Apr 12 '22 at 13:12
  • How could we match *.heic and *.HEIC files in the for loop? – philshem Nov 09 '22 at 19:37
  • Using the last command (`find ...`) I got a "parse error near done". I had to add a semicon after "read i" so the first line reads `find . -type f -iname '*.heic' | while read i; do` – Markus Dec 04 '22 at 12:51
37

We just released this little free app for macOS: https://imazing.com/heic

Minimum macOS version is 10.8, so no worries with El Capitan. : )

enter image description here

Macmade
  • 518
  • 4
  • 5
10

Use the built-in "Convert Image" macOS Quick Action to easily convert HEIC images to JPEG.

Convert Image Quick Action

the right-click menu item opens up a small utility for converting to various formats and sizes:

Convert Image

pkamb
  • 7,183
  • 9
  • 60
  • 99
  • 1
    this is elegant! – zx1986 Jul 09 '22 at 09:32
  • Hmm I did that and it worked. But the image is in low quality, even though I selected "actual size". Furthermore: Now when I copy any other image from the Photos App to a new folder in Finder, its automatically in "low" quality and in ".jpeg" format instead of ".heic". Do you know how to revert this? – JiiB Nov 02 '22 at 08:46
7

I found Dropbox to be a good conversion tool, as it does it transparently for the usage on any operating system and platform.

When you do the shot from iPhone, Dropbox automatically converts .heic image to .jpg when uploading it to computer (controlled by the settings). Since I'm using both Windows OS and MacOS, there's no need to install separate additional applications.

Farside
  • 1,573
  • 3
  • 16
  • 36
3

Below an online (web browser) conversion tool: doesn’t support batch processing but it will work on a wide range of systems, including non-Apple OSs.

http://heictojpg.com/

cbuchart
  • 189
  • 1
  • 8
  • 1
    This website now lets you upload up to 50 images at once. – kuzzooroo Apr 19 '19 at 19:11
  • Keep in mind: you are uploading your pics to a third-party cloud service (and you have no guarantee they will delete them afterward). Do not use it for personal stuff, – jnardiello Dec 29 '22 at 11:00
2

An excellent command line tool that works very well is tifig. It can be easily compiled on multiple platforms. It should compile on any platform with a relatively modern development toolchain, that should include El Capitan!

  • I followed the instructions in the repo to install `tifig` using `brew install cmake vips ffmpeg` (from the repo) but it doesn't seem to work (`tifig command not found`). – Amelio Vazquez-Reina Oct 08 '18 at 21:28
  • I don't know if you did or not, but you have to follow the build instructions as well. To execute inside build folder after build, just run `./tifig -v -p file.heic file.jpg` – kentrh Dec 13 '18 at 17:41
  • 1
    Could a demo brew install and usage be provided to turn this into a more complete answer? As it stands it's more of a comment. – oliversm Apr 01 '20 at 23:35
2

my two cents for Catalina.

I was tired of using cmd line...

I wrote a small app... if interested. it's free:

https://apps.apple.com/us/app/heictojpeg/id1486256731?ls=1&mt=12

hope can be useful :)

ingconti
  • 149
  • 4