Images have all sorts of meta information saved along side what pixels should look like. The “Exchangeable image file format” (EXIF) standard allows digital images to be tagged with cameras settings, date and time information, copyright information and location. For serious photographers this information provides a powerful learning resource. When posting to the internet, however, that information can expose details better kept private.
As a Mac user, when I looked into this issue myself FOSS ImageOptim rose to the top as a simple drag and drop GUI that strips EXIF and makes images smaller for the web. Their optimization algorithms can also be used in scripts using their node package. They also provide alternatives for Windows and Linux users.
I learned about ImageOptim from an article on HowToGeek which showed how to remove EXIF using native mac and windows tools and how to change the phone settings keep the location data from showing up in the first place. Also handy, an article from MakeUseOf shows how to use GIMP to remove the EXIF. Caesium provides an online drag and drop tool.
The winner of the command line tools to clean up EXIF data appears to be ExifTool, which also has a node package. I’m a fan of imageMagick, but it appears to resample JPGs in the process of striping meta data with -strip, so if EXIF removal is all that’s wanted it isn’t the way.
As a photography fan the loss of information makes me sad, but removing EXIF data before posting casual shots on social media keeps phone and location data private.