Why does ExifTool shift times by 1 hour when copying FileModifyDate to EXIF dates around BST/GMT?
Asked 11/25/2010
8 views
2 answers
0
I’m using ExifTool on Windows to copy file modified timestamps into EXIF date fields with:
exiftool -v "-FileModifyDate>AllDates" *
For files shot during British Summer Time, the EXIF times end up 1 hour earlier after the switch back to GMT. For example:
- file modified time: 11:00 during BST →
DateTimeOriginalbecomes 10:00 - file modified time: 11:00 during GMT →
DateTimeOriginalbecomes 11:00
Is this expected behavior? Is there a way to make ExifTool use the exact file modified time without applying daylight saving or timezone conversion?
Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0
Photography Stack Exchange contributor
15y ago
2 Answers
3
You know, I bumped into something like this a few days ago.
I decided that from here on out, all my cameras will be set to UTC no matter where I am or whether it's daylight savings time.
Then, there won't be any need to figure out what time zone a given timestamp is in, or deal with changing the camera's clock when daylight time starts or ends. (FWIW, I went to make the latter change only to discover that it was still set to the time zone I had put in for a trip months ago. That's what prompted the decision.)
Originally by user27. Source · Licensed CC BY-SA 4.0
user27
15y ago
0
Generated from our catalog & community — verify before relying on it.
Yes—this is expected. File system timestamps are interpreted using the system’s local time zone rules, including daylight saving time, while standard EXIF date fields typically do not store a time zone. That can make copied times appear off by an hour when files span BST/GMT changes.
A practical workaround is to run the command with the time zone fixed so the timestamp is interpreted consistently, for example by setting the TZ environment variable to GMT/UTC before running ExifTool. On Unix-like systems this can be done in the shell; Windows may also support setting TZ, depending on environment.
More generally, this happens because the timestamp standard being used doesn’t reliably encode the original time zone. To avoid future ambiguity, many photographers keep camera clocks set to UTC year-round instead of local time.
Recommended products
UniqueBot
AI15y ago
Your Answer
Related Questions
ExifTool on Windows: move images whose file modified date is later than DateTimeOriginal
How can I batch-edit EXIF date/time for multiple photos across a time range?
How can I keep only one timelapse photo per hour from a week of 1-second shots?
Why does a GoPro Hero3+ Black reset its date and time after the battery is removed?
Does rating a JPEG in Lightroom Classic change the original file?