Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What tools can I use to delete all the EXIF, IPTC, XMP, etc metadata from graphics files?

share|improve this question

Try exiftool (which is written in perl):



exiftool -all= image.jpg
share|improve this answer

jhead can be used to delete metadata from JPG files. The following command line options to jhead are available (quoting the man page for jhead below):

   -dc    Delete comment field from the JPEG header.  Note that the comment is not part of the Exif header.
   -de    Delete the Exif header entirely.  Leaves other metadata sections intact.
   -di    Delete the IPTC section, if present.  Leaves other metadata sections intact.
   -dx    Delete the XMP section, if present.  Leaves other metadata sections intact.
share|improve this answer

There is an option for exiv2 to delete image metadata.

By default, the exiv2 subcommand rm (or delete) removes Exif thumbnails and JPEG comments also, additional to the ones you mention (EXIF, IPTC, XMP):

$ exiv2 rm test.jpg

Use the option -d to delete only parts of the metadata.
From man exiv2:

-d tgt Delete target(s) for the 'delete' action. Possible targets are:
       a : all supported metadata (the default)
       e : Exif section
       t : Exif thumbnail only
       i : IPTC data
       x : XMP packet
       c : JPEG comment
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.