# The Hidden Metadata Problem With Image Format Conversion

One easy-to-miss issue in image conversion pipelines is that changing format is not only a pixel operation. Each format stores metadata differently, and what survives the conversion depends on which containers and representations the source and target formats support.

If you've been batch-converting images to WebP without checking the output metadata, you may have been losing legacy IPTC-IIM data on every single conversion — silently, without errors, without warnings.

## Three Metadata Representations, Five Container Formats

Images can carry metadata in three major representations:

- **EXIF**: Camera settings, GPS coordinates, timestamps, orientation
- **Legacy IPTC-IIM**: Older embedding for copyright, creator credits, keywords, captions, contact info
- **XMP**: Extensible standard — descriptions, ratings, edit history, and modern IPTC Photo Metadata (IPTC Core/Extension properties)

An important distinction: the IPTC Photo Metadata Standard today defines IPTC Core and IPTC Extension properties implemented in XMP. Legacy IPTC-IIM is a separate, older representation. Many fields — such as Copyright Notice, Creator, and Keywords — exist in both representations.

Each image format stores these in format-specific containers:

```plaintext
JPEG:  EXIF → APP1 | Legacy IIM → APP13 | XMP → APP1
PNG:   EXIF → eXIf chunk | XMP → iTXt chunk | Legacy IIM → varies
WebP:  EXIF → RIFF chunk | XMP → RIFF chunk | Legacy IIM → ❌ NO CONTAINER
HEIC:  EXIF → ISOBMFF | XMP → ISOBMFF | Legacy IIM → limited
TIFF:  EXIF → IFD | Legacy IIM → IFD | XMP → IFD (full support)
```

Notice WebP. There is no standard legacy IPTC-IIM container in the WebP specification. This isn't a bug in any particular tool — it's a gap in the format spec itself. However, IPTC Photo Metadata properties represented in XMP can potentially be carried in WebP's XMP chunk.

## Why This Matters

Legacy IPTC-IIM fields include:

- **Copyright Notice** — Legal ownership information
- **Creator/By-line** — Photographer or creator name
- **Keywords** — Searchable tags embedded in the file
- **Caption/Description** — Human-readable image description
- **Source and Credit** — Attribution information

Many of these same fields have XMP representations (via IPTC Core). If a workflow stores rights information only in legacy IPTC-IIM and converts to WebP without mapping equivalent fields into XMP, that rights metadata may be lost. But if the same properties are also represented in XMP, they may survive in WebP's XMP packet.

Google can read supported IPTC Photo Metadata fields from appropriate embedded representations. If your workflow relies exclusively on legacy IIM for licensing metadata and you convert to WebP without ensuring equivalent XMP mappings exist, verify the resulting metadata and consider using supported page-level structured licensing metadata as well.

## Conversion Compatibility Quick Reference

Here is a practical compatibility summary for common conversion paths:

| Path | EXIF | Legacy IPTC-IIM | XMP | Alpha |
| --- | --- | --- | --- | --- |
| HEIC → JPG | Can be preserved | Depends on converter | Can be preserved | Lost |
| HEIC → WebP | Can be preserved | No IIM container | Can be preserved | Kept |
| JPG → WebP | Can be preserved | No IIM container | Can be preserved | N/A |
| JPG → PNG | Can be preserved | ⚠️ Implementation-dependent | Can be preserved | N/A |
| PNG → JPG | Can be preserved | ⚠️ Implementation-dependent | Can be preserved | Lost |
| PNG → WebP | Can be preserved | No IIM container | Can be preserved | Kept |
| TIFF → any | Can be preserved | Depends on target format | Can be preserved | Depends |

⚠️ = implementation-dependent (PNG legacy IPTC-IIM support isn't universally standardized)

**Note:** "Can be preserved" means the target format supports this representation — actual preservation requires the converter to explicitly transfer the metadata.

## How Browser-Based Conversion Handles This

The architecture [GeoImageTagger's Image Converter](https://geoimagetagger.com/tools/image-converter) uses is interesting even if you're building your own pipeline.

The conversion uses a two-stage approach:

**Stage 1: Pixel encoding in the browser.** WebAssembly builds of three encoders handle the actual format conversion:

- `MozJPEG` for JPG output
- `OxiPNG` for PNG output
- `libwebp` for WebP output

These encoders work on raw pixel data and produce a "clean" output file with no metadata. The conversion never leaves your browser.

**Stage 2: Metadata injection server-side.** ExifTool copies metadata fields from the original file into the converted output. The server verifies the transfer and reports whether all original fields were confirmed present.

This two-stage split is necessary because WASM image encoders don't handle metadata — they're pixel processors. If you're building your own conversion pipeline, you need explicit metadata handling. A two-stage encode-then-metadata-transfer workflow is one practical approach, as used here and with tools like `sharp` or `Pillow`.

```bash
# ExifTool example — copy metadata between formats
exiftool -TagsFromFile source.jpg -all:all converted.webp

# Verify what transferred
exiftool -G converted.webp | grep -i "iptc\|xmp"
# Legacy IPTC-IIM fields won't appear; check XMP for IPTC Core properties
```

## Practical Decisions

**Choose JPG output** when:

- Legacy IPTC-IIM preservation is non-negotiable
- You need maximum compatibility with metadata-reading tools across all representations
- Transparency isn't needed

**Choose WebP output** when:

- Web delivery is the priority
- Your metadata is primarily EXIF and XMP
- You can verify that any needed IPTC properties have XMP representations

**Choose PNG output** when:

- You need lossless quality
- Transparency must be preserved
- File size is less important than fidelity

## Always Verify

The most important habit: verify metadata after every conversion. Open your output file in a [Metadata Viewer](https://geoimagetagger.com/tools/metadata-viewer) and specifically check for:

1. GPS coordinates (EXIF) — especially important for geotagged images
2. Copyright fields — check both legacy IIM and XMP representations
3. Keywords — legacy IPTC-IIM keywords cannot be stored as IIM in WebP, but XMP keywords can survive
4. Camera data — EXIF can be preserved across all formats when the converter handles the transfer

The GeoImageTagger converter includes a built-in before/after comparison, but independent verification with a dedicated viewer catches edge cases.

## The Bottom Line

Format conversion and metadata preservation are two separate problems that happen to occur at the same time. Understanding which metadata representations each format supports — and specifically the distinction between legacy IPTC-IIM and IPTC Photo Metadata in XMP — puts you in control of what your images carry after conversion.

For a deeper dive into metadata standards themselves, check out the [full explanation of EXIF, IPTC, XMP, and GPS metadata](https://geoimagetagger.com/blog/understanding-image-metadata-exif-iptc-xmp-gps-data). And if your goal is reducing file size without changing formats, there's a companion guide on [compressing without losing metadata](https://geoimagetagger.com/blog/compress-images-without-losing-metadata).

*For the complete guide, see [How to Convert HEIC, JPG, PNG and WebP Without Losing Image Metadata](https://geoimagetagger.com/blog/convert-images-without-losing-metadata).*
