Skip to main content
100%

Extract EXIF from image in Python

✓ Published0🌍 Public
VVioletVivirand
Last edited Aug 26, 2025
Created on Feb 13, 2025

This example demonstrates how to extract EXIF metadata from an image file in Python using the Pillow library. It first prints the raw image information and the EXIF bytes stored in the `info` dictionary, then iterates through the parsed EXIF tags with both the modern `getexif()` method and the deprecated `_getexif()` method. Each tag’s numeric key is translated to a human-readable name using `ExifTags.TAGS`, and the results are printed as key-value pairs. The code shows two equivalent API approaches for accessing the same metadata.

AI-generated description

Similar vizzes