Skip to content
🛠️ToolsShed

EXIF Viewer

Extract and display EXIF metadata from JPEG images: camera, date, GPS, and more.

About this tool

EXIF Viewer is a browser-based tool that extracts and displays the hidden metadata embedded in JPEG images, revealing details like camera model, lens specifications, shooting date and time, and GPS location coordinates. This information, known as EXIF (Exchangeable Image File) data, is automatically recorded by digital cameras and smartphones but often remains invisible to regular viewers. Understanding your image metadata is valuable for photographers who want to review technical settings, verify location data, or audit privacy-sensitive information before sharing photos online.

To use the tool, simply upload a JPEG image from your device or drag and drop it into the viewer. The tool instantly parses all available EXIF fields and displays them in an organized, easy-to-read format, including camera specifications, exposure settings (ISO, aperture, shutter speed), white balance, and GPS coordinates if available. No server upload occurs—all processing happens entirely in your browser, ensuring your images remain private and processing is instantaneous. Common use cases include photographers reviewing their camera settings for learning purposes, travel bloggers checking GPS data embedded in photos, and users checking what metadata might be exposed before uploading to social media.

Frequently Asked Questions

Code Implementation

# Read EXIF metadata from a JPEG using Pillow + piexif
# pip install Pillow piexif

from PIL import Image
import piexif
import json

def read_exif(path: str) -> dict:
    img = Image.open(path)
    exif_bytes = img.info.get("exif", b"")
    if not exif_bytes:
        return {}

    exif_dict = piexif.load(exif_bytes)
    result = {}

    tag_names = {**piexif.ImageIFD.__dict__, **piexif.ExifIFD.__dict__, **piexif.GPSIFD.__dict__}
    tag_names = {v: k for k, v in tag_names.items() if isinstance(v, int)}

    for ifd_name in ("0th", "Exif", "GPS", "1st"):
        for tag, value in exif_dict.get(ifd_name, {}).items():
            name = tag_names.get(tag, f"Tag_{tag}")
            if isinstance(value, bytes):
                try:
                    value = value.decode("utf-8").rstrip("\x00")
                except UnicodeDecodeError:
                    value = value.hex()
            result[name] = value

    return result

exif = read_exif("photo.jpg")
for k, v in exif.items():
    print(f"{k}: {v}")

# GPS coordinates helper
def dms_to_decimal(dms, ref):
    d, m, s = [x[0] / x[1] for x in dms]
    decimal = d + m / 60 + s / 3600
    if ref in ("S", "W"):
        decimal = -decimal
    return round(decimal, 6)

if "GPSLatitude" in exif and "GPSLongitude" in exif:
    lat = dms_to_decimal(exif["GPSLatitude"], exif.get("GPSLatitudeRef", "N"))
    lon = dms_to_decimal(exif["GPSLongitude"], exif.get("GPSLongitudeRef", "E"))
    print(f"GPS: {lat}, {lon}")

Comments & Feedback

Comments are powered by Giscus. Sign in with GitHub to leave a comment.