An ICC profile is a small binary block, usually a few kilobytes, that tells color-managed software what the RGB numbers in an image mean. The triplet (255, 0, 0) is a different red in sRGB, Adobe RGB and Display P3, and the profile is how a browser or Photoshop knows which one to show. The EXIF ColorSpace tag is a rough hint next to it. iPhone HEIC photos, for example, carry a profile named Display P3.
Where each format keeps it
| Format | Container |
|---|---|
| JPEG | APP2 segments starting with ICC_PROFILE, numbered if the profile needs more than one |
| PNG | iCCP chunk, zlib-compressed, with a profile name |
| WebP | ICCP chunk, after the extended VP8X header |
| TIFF | Tag 0x8773 in IFD0 |
ExifTool's -v option shows the containers. With the same 3196-byte profile embedded by Pillow, the JPEG had JPEG APP2 (3210 bytes): ICC_Profile chunk 1 of 1, the PNG had PNG iCCP (1427 bytes) and the WebP a RIFF 'ICCP' chunk right after VP8X.
Reading, extracting, embedding
exiftool -G1 -s -ICC_Profile:ProfileDescription -ICC-header:ColorSpaceData -ICC-header:ProfileVersion photo.jpg
exiftool -icc_profile -b photo.jpg > profile.icc
exiftool "-icc_profile<=profile.icc" other.jpg[ICC_Profile] ProfileDescription : ProPhoto RGB
[ICC-header] ColorSpaceData : RGB
[ICC-header] ProfileVersion : 4.4.0With -G all of these report the group ICC_Profile.
What stripping does
Without a profile, software assumes sRGB. For an sRGB image nothing changes. A Display P3, Adobe RGB or ProPhoto image looks duller, because its values are now shown on a smaller gamut. ExifTool warns when you delete one:
Warning: ICC_Profile deleted. Image colors may be affected - photo.jpgOur metadata remover runs exiftool -all=, which deletes the profile with everything else. For wide-gamut files, strip with ExifTool and copy the profile back:
exiftool -all= -tagsfromfile @ -icc_profile photo.jpgThat command still prints the warning, but the profile is back in the output file. More on full strips in the metadata removal guide.