GPS in photos.

The field that makes people care. A phone photograph usually knows where it was taken to within a few metres, and it takes that knowledge with it everywhere.

// definition

Geotagging is the recording of a location into an image file at capture time. In a JPEG the coordinates live in the GPS sub-directory of the EXIF block: latitude, longitude, often altitude, and a UTC timestamp, usually written by the phone without anything being switched on deliberately.

What it is

The GPS pointer tag in EXIF's IFD0 leads to a small directory of its own. Latitude and longitude are stored as three rational numbers each — degrees, minutes, seconds — with a separate reference tag for the hemisphere. Precision in practice is a handful of metres, and often better outdoors.

Nothing about the file signals that it is there. A geotagged photograph looks exactly like one that is not.

Why it matters

This is the field that turns "a photo of my living room" into an address. A set of photographs shared over months maps a routine. A single photo of something for sale online places the seller's home. The risk is not exotic and it does not require an adversary with resources — reading it takes one command.

It is also the field people most often assume has already been handled for them. It usually has not.

// in ScrubPony scrubpony -n reports GPS present when a file carries coordinates, and the summary at the end of a run counts them: 257 carried GPS coordinates. That line prints even when nothing went wrong, because it is the part worth reading. --check mentions GPS explicitly in its per-file output.

Related terms

Common questions.

Can I turn geotagging off instead?

Yes, and you should if you never want it — the setting is in your phone's camera or location permissions. It only applies to photos taken afterwards, though, so the library you already have still needs scrubbing.

Does GPS appear anywhere other than EXIF?

Yes. XMP packets often duplicate the coordinates, and some vendors record location in their own segments. ScrubPony drops XMP outright and drops unrecognised APPn segments by default.

Is the coordinate exact?

It is as good as the phone's fix at the time, typically within a few metres outdoors and worse indoors. Treat it as identifying regardless.

Get ScrubPony

Strips identifying metadata out of JPEGs without touching a pixel. C99, no dependencies beyond libc, macOS and Linux, MIT-licensed.