Tutorials Developer

Media Metadata Standards: EXIF, XMP, and Sidecars

By Infinite Creation · Intermediate · ~18 min
A 1960s mid-century comic book style editorial illustration showing two engineers at terminals in a machine room, with a camera on a tripod, labelled archive boxes and reels, a set of prime lenses visible in the frame.

Overview

Metadata is what makes an archive searchable, and it is stored in a surprising number of incompatible places: embedded in the file, in a companion sidecar, in a database, or in all three and disagreeing. Understanding which standard applies to which medium, and which survives which operation, is what prevents an archive from gradually losing the information that made it useful. This guide covers the main standards, where each lives, and the specific operations that strip them.

What You Need

  • A tool that can inspect embedded metadata. ExifTool is the standard
  • Sample files from each source you work with
  • Knowledge of what your asset system stores versus what the files carry
  • A test upload to each platform you publish to
  • A decision about what is authoritative when they disagree
  • A policy on what to strip before publishing, and what to keep

Steps

1

Learn which standard applies to your medium

EXIF carries camera and capture data on photographs: exposure, lens, timestamp, and often location. IPTC carries editorial information such as caption, creator, and rights, and is the press and stock convention. XMP is Adobe's extensible framework that can carry both and is widely supported. Video uses a looser mix of container-level fields and production-specific standards.

2

Understand embedded versus sidecar storage

Embedded metadata lives inside the file and travels with it. Sidecar files sit alongside as separate files: common for raw photography, where the raw file is left untouched and edits and metadata go in a companion. Sidecars preserve the original perfectly and are trivially lost, because copying the media file without its sidecar is easy to do accidentally.

3

Decide what is authoritative

When the file, the sidecar, and your asset database disagree, and they will, something has to win. Most teams make the asset system authoritative and treat embedded metadata as a snapshot written on export. Whatever you choose, write it down, because inconsistent answers are how archives become untrustworthy.

4

Know what strips metadata

Most social platforms remove embedded metadata on upload. Screenshotting, re-encoding, and many conversion tools drop it. Some messaging apps strip it and some do not. Assume anything published to a platform loses its metadata, which matters both for attribution you wanted to keep and for location data you did not want to publish.

5

Strip deliberately before publishing

Photographs frequently carry GPS coordinates and device identifiers. Publishing those attached to an image taken at home is a genuine privacy problem, and it is invisible unless you check. Decide what should be removed before publication and automate it rather than relying on each platform's behaviour. Check the output file, because one command does not strip everything. In our test, stream copying with -map_metadata -1 emptied an MP4 and a WAV file but left a JPEG's EXIF fields, GPS position included, and converting a JPEG to PNG kept the GPS position.

6

Write your own metadata at ingest, not at delivery

Creator, rights, project, and description should be applied when material enters your system, while the context is known. Metadata added at delivery is metadata that was missing for the entire life of the asset inside your archive, which is exactly when you needed it to find things.

Pro Tips

  • ExifTool reads and writes essentially everything and is worth learning even briefly. It is the reference implementation for this whole area.
  • Never assume metadata survived a round trip. Check the output file, not the input.
  • Keep sidecars in the same folder as their media and move them together. They are trivially orphaned.
  • Timestamps are the most commonly corrupted field, timezone handling differs between tools and devices.
  • Strip location data from anything shot at home or in a private location before it is published.

Tested: which operations keep or strip metadata in FFmpeg and Pillow

We tested the page's claims about what strips metadata on 2026-09-29 with FFmpeg 8.1.2, ffprobe and Pillow 12.3.0, on generated files. Seven fields (title, artist, comment, copyright, creation date, a custom project field and a location) were written into each container, and a JPEG got make, model, date, orientation and a GPS position. Each file was then copied, re-encoded, converted or stripped and the result was read back. ExifTool, the page's recommended reader, is not installed on the machine we used, so nothing here was read with it. No platform, screenshot or messaging app was tested.

Starting fileOperationFields still presentFields lost
MP4, written by FFmpegSeven fields written6 of 7custom project field
MKV, written by FFmpegSeven fields written7 of 7none
WAV, written by FFmpegSeven fields written4 of 7creation date, custom project field, location
MP3, written by FFmpegSeven fields written7 of 7none
FLAC, written by FFmpegSeven fields written7 of 7none
MP4, from a file holding 6Re-encoded, same container5 of 6creation date
MKV, from a file holding 7Stream copy to MP45 of 7creation date, custom project field
MKV, from a file holding 7Re-encoded to WebM6 of 7creation date
WAV, from a file holding 4Converted to MP34 of 4none
MP3, from a file holding 7Converted to WAV4 of 7creation date, custom project field, location
MP3, from a file holding 7Converted to FLAC6 of 7creation date
MP4, from a file holding 6Stream copy with -map_metadata -10 of 6title, artist, comment, copyright, creation date, location
WAV, from a file holding 4Copy with -map_metadata -10 of 4title, artist, comment, copyright
JPEG with EXIF and GPSStream copy5 of 5none
JPEG with EXIF and GPSRe-encoded at high quality0 of 5make, model, date, orientation, GPS
JPEG with EXIF and GPSScaled and re-encoded0 of 5make, model, date, orientation, GPS
JPEG with EXIF and GPSStream copy with -map_metadata -15 of 5none
JPEG with EXIF and GPSConverted to PNG4 of 5orientation
JPEG with EXIF and GPSPillow open and save, defaults0 of 5make, model, date, orientation, GPS
JPEG with EXIF and GPSPillow save with exif passed5 of 5none

Re-encoding audio and video with FFmpeg did not drop container metadata. By default it copies the fields across, so a re-encoded MP4 kept exactly what a stream copy kept, and the one field that went missing in both was the creation date, which did not survive an MP4 to MP4 pass in this build. The page says re-encoding and many conversion tools drop it, and that depends on the tool: Pillow's plain open and save did drop every EXIF field from the JPEG, and FFmpeg's re-encode of the same JPEG did as well.

What was lost mostly came from the destination container, not the operation. MP4 held six of the seven fields we wrote and left out the custom project field, WAV held four, and Matroska, MP3 and FLAC held all seven. Going from Matroska to MP4 lost the creation date and the custom field, and from MP3 to WAV lost three. Once a field is lost this way it is not there to return when the file is converted back. The page's advice not to treat embedded metadata as a system of record is borne out.

Step 5 had a trap in it, and now says so. Stream copying a JPEG with -map_metadata -1, the option that emptied the MP4 and WAV files above, left all five EXIF fields, GPS position included, in the JPEG. A re-encode or a resize with FFmpeg removed them, but converting to PNG kept the GPS position and lost only the orientation. So the command that strips a video does not strip a photograph, and checking the output file, as the page says, is the only way to know.

Pillow shows the other side of it. Saving a JPEG with its defaults dropped all EXIF, and passing the EXIF explicitly kept all of it. Whether a tool preserves metadata is a setting, and the default differs between tools.

Check what a file still carries, and strip the container fields of a video: ffprobe -v error -show_entries format_tags -of default=nw=1 out.mp4 && ffmpeg -i in.mp4 -c copy -map_metadata -1 out.mp4

Validated. Run 2026-09-29 with FFmpeg 8.1.2, ffprobe and Pillow 12.3.0 on generated files. Results are for these tools and versions. Each field counts as present when ffprobe lists it as a container tag. We did not test IPTC, XMP, sidecar files, ExifTool, video-specific fields such as timecode and reel name, any platform's upload processing, screenshots, or messaging apps, and we cannot say from this what any of them strip. The command is the one that was measured on video files, not on JPEG.

What You'll Learn

This is reference material rather than a workflow, because the useful knowledge is which standard applies where. Below: what each standard is for, and why metadata loss is so routine.

The Standards, and What Each Is For

EXIF originated for digital photography and carries capture-time technical data: shutter speed, aperture, ISO, focal length, camera and lens identification, orientation, timestamp, and frequently GPS coordinates. It is written by the camera and is generally not the right place for editorial information.

IPTC comes from the news industry and carries editorial and rights fields: caption, headline, keywords, creator, credit, copyright, and usage terms. It is the standard press agencies and stock libraries expect, and it is what makes an image legally and editorially self-describing.

XMP is an extensible framework rather than a fixed field list. It can carry EXIF and IPTC data alongside application-specific information, and it is what most modern tools read and write. It can be embedded or held in a sidecar.

Video is less unified. Containers carry basic fields, cameras write manufacturer-specific data, and production workflows layer on timecode, reel names, and scene/take identification. This fragmentation is a large part of why video asset management leans so heavily on an external database rather than on embedded metadata.

Why Metadata Disappears So Routinely

Metadata loss is the normal case rather than an exception, and knowing the causes lets you plan around it.

Platforms strip it deliberately. Most social and publishing platforms remove embedded metadata on upload, partly for privacy, partly for file size, and partly because they generate their own. Anything you published is unlikely to still carry your attribution.

Re-encoding drops it. Many conversion and export operations write a new file and carry over only the fields the tool happens to support, silently discarding the rest.

Sidecars get orphaned. Copy the media file without its companion and the metadata is simply gone, with nothing to indicate it ever existed.

Tools disagree. The same conceptual field exists in several standards, and applications differ on which they read and write, so information can be present but invisible to the tool you are using.

The practical consequence is that embedded metadata is a convenience rather than a system of record. Anything you cannot afford to lose belongs in a database you control.

Where This Fits

Metadata standards decide what survives a move, and Media Asset Management (MAM) Explained shows how a schema fits into the rest of an asset system.

FAQ

Q: What is the difference between EXIF, IPTC, and XMP?
A: EXIF is capture-time technical data written by the camera, exposure, lens, timestamp, often GPS. IPTC is editorial and rights information such as caption, creator, and copyright. XMP is an extensible framework that can carry both plus application-specific fields, and is what most modern tools read and write.

Q: Does metadata survive uploading to social platforms?
A: Usually not. Most platforms strip embedded metadata on upload for privacy, file size, and their own processing reasons. Assume published copies carry no metadata, which matters both for attribution you wanted preserved and for location data you did not want published.

Q: What is a sidecar file and should I use one?
A: A companion file holding metadata and edit information alongside an untouched original, common in raw photography. It preserves the source perfectly, which is its main virtue, and it is easily orphaned by copying the media file alone. Use it where your tools expect it, and always move the pair together.

Q: Should I strip metadata before publishing?
A: Deliberately, yes: particularly location data on anything shot at home or somewhere private, and device identifiers. Decide what should be removed and automate the removal rather than relying on each platform behaving as you expect, since their behaviour varies and changes.

Translate this page

Machine translation provided by Google Translate, on Google’s servers. We do not check these translations and they will get technical terms wrong. The English page is the authoritative one. Following a link sends this page’s address to Google. Your browser may also offer to translate this page itself, which keeps the request on your device.