Last Updated: November 05, 2020
·
23.36K
· magalhini

Convert RAW photos to JPG in the Mac OS terminal

No need for slow and heavy Photoshop scripts for this one, you can do easily do this right from your terminal window.

This is possible using "sips", an image editing tool already available on Mac which allows you to do all sorts of image manipulation, including resizing and converting.

  • So we first grab all RAW files in a folder,
  • We convert them to jpeg (or any other format),
  • And we output them somewhere else.

    for i in *.CR2; do sips -s format jpeg $i --out "${i%.*}.jpg"; done

So you now can save some space in your card by skipping the RAW + JPG option :)

4 Responses
Add your response

Wow....Learn something new everyday. Thanks so much for this.

over 1 year ago ·

THANK YOU!!!

over 1 year ago ·

Cant get it to work with CR2 here in 2018, works fine with other formats thought, so did CR2 change in some way?

over 1 year ago ·

Good tip!

If you want the output jpegs be in sRGB color profile (instead of the default and Apple specific Display P3 ), then modify the command to:

for i in *.NEF; do sips -s format jpeg --matchTo "/System/Library/ColorSync/Profiles/sRGB Profile.icc" $i --out "${i%.*}.jpg"; done

over 1 year ago ·