What does it mean when you have two identical files with identical time stamps, yet Windows says that one file is newer than the other one? How can that be? Today’s SuperUser Q&A post helps a confused reader solve a time stamp mystery.

Today’s Question & Answer session comes to us courtesy of SuperUser—a subdivision of Stack Exchange, a community-driven grouping of Q&A web sites.

The Question

SuperUser reader WBT wants to know how Windows decides which of two files with identical time stamps is newer:

How does Windows decide which of two files with identical time stamps is newer?

At first, I thought Windows was comparing the date created attribute and using the result of that comparison to label one or the other as newer. If a file was copied into a particular location, it may have the creation date of when the copy was made rather than the creation date of the original file. However, after reproducing it with another file, the result of which one is newer seems to be the opposite:

The result is the same whether copying or moving the file:

And for background, the file in test2 is a previously made copy of the file in test1.

The Answer

SuperUser contributor grawity has the answer for us:

Have something to add to the explanation? Sound off in the comments. Want to read more answers from other tech-savvy Stack Exchange users? Check out the full discussion thread here.

Note: Most file systems measure times in μs or ns. FAT32 is a bit of a relic and rounds timestamps to two seconds.

Try one of the following methods to compare the full time stamps:

wmic datafile where name=”c:\foo\bar. txt” get lastmodified

Via PowerShell:

(Get-ChildItem c:\foo\bar. txt). LastWriteTime. ToString(“o”)

Image Credit: WBT (SuperUser)