Skip to main content
Adobe Photoshop Family



5.1K Messages


92.6K Points

Sun, Mar 31, 2013 2:58 PM

Lightrooom: Edit Capture Time leaves NEF files inconsistent

It appears that at least some NEF files do not strictly follow the Exif standard, causing LR's Metadata > Edit Capture Time command to record inconsistent values in the files. LR could insist that Nikon strictly follow the standard (which wouldn't address NEF files produced by existing Nikon cameras), or it could easily accommodate NEF files with a simple workaround.


NEF files appear to record DateTimeOriginal in both ExifIFD and IFD0, though the Exif standard says it should appear in just ExifIFD. For example, consider this sample D600 NEF from DPReview:

Here's what Exiftool shows:

$ exiftool.exe -a -G1 ISO100.NEF | grep -i "date/time"

[IFD0] Date/Time Original : 2012:03:01 07:59:05
[ExifIFD] Date/Time Original : 2012:03:01 07:59:05
[Composite] Date/Time Original : 2012:03:01 07:59:05.40

Note that DateTimeOriginal is recorded in both IFD0 and ExifIFD. In LR 4.4RC, when I give Metadata > Edit Capture Time followed by Metadata > Save Metadata To File, LR correctly updates ExifIFD:DateTimeOriginal, while it leaves IFD0:DateTimeOriginal untouched:

$ exiftool.exe -a -G1 ISO100.NEF | grep -i "date/time"
[IFD0] Date/Time Original : 2012:03:01 07:59:05
[ExifIFD] Date/Time Original : 2013:03:01 07:59:05
[Composite] Date/Time Original : 2012:03:01 07:59:05.40

This results in inconsistent values for ExifIFD:DateTimeOriginal and IFD0:DateTimeOriginal.

At least two tools get confused by this. Exiftool itself gives preference to IFD0:DateTimeOriginal when reading the value. And Nikon's NEF codec for Windows also appears to give preference to IFD0.

LR could easily accommodate NEF's nonconformance by doing what Exiftool does: Always write ExifIFD:DateTimeOriginal, but if IFD0:DateTimeOriginal is present, update that as well. This would handle all the existing Nikon cameras without waiting for Nikon to conform with the standard.

See this thread for more details:


2 Messages


80 Points

6 years ago

It doesn't work with raw files from Canon and a German LR 5 either

111 Messages


2.3K Points

6 years ago

Thank you for the technical info about the proprietary date-time metadata in NEF and how other software (like Nikon's codec) prioritize reading the apparently redundant tags.

As long as this limitation exists, and you want to take the risk of modifying your NEF files instead of treating them exclusively read-only (Lightroom's default behavior), I suggest you investigate using Nikon's software to change the date time or perhaps using Exiftool. Personally, I'd recommend that you incorporate into your workflow saving a backup of the original, un-edited, NEFs as well.


438 Messages


6.5K Points

6 years ago

ExifToolGUI deletes the wrong entry in IFD0 and just leaves the correct entry in IFD (according to Phil Harvey). Just confirmed that with my nefs.

bob Frost

115 Messages


1.6K Points

5 years ago

The problem still exists in LR 6.0.1 / OS X 10.10.3.