What are the steps to restore file creation dates on Mac?

On the Mac you used to be able to see actual creation date of an any file, then a modified date and so on. Is there a simple way to restore that setting other than some kind of coding process. I've got a mess of files I needed to keep time on and that would have been the previously simple way.




[Re-Titled by Moderator]

MacBook Pro 14″, macOS 14.6

Posted on Apr 13, 2025 03:01 PM

Reply
Question marked as Top-ranking reply

Posted on Apr 13, 2025 03:16 PM

Every file on macOS has a creation and modification date. You can see these in a Finder Window columns when in List View (cmd+2), or available by right-clicking on a file and selecting Get Info. This has not changed in decades.


Although you can change the creation/modification date on a file, it must be done in the Terminal with either the touch(1) utility or by installing the command line tools for Xcode and using the now deprecated SetFile(1) command. If you are not comfortable in the Terminal, I would advise against going there.


More on this here: Change the Modification and Creation date… - Apple Community


13 replies
Question marked as Top-ranking reply

Apr 13, 2025 03:16 PM in response to RedJeryl

Every file on macOS has a creation and modification date. You can see these in a Finder Window columns when in List View (cmd+2), or available by right-clicking on a file and selecting Get Info. This has not changed in decades.


Although you can change the creation/modification date on a file, it must be done in the Terminal with either the touch(1) utility or by installing the command line tools for Xcode and using the now deprecated SetFile(1) command. If you are not comfortable in the Terminal, I would advise against going there.


More on this here: Change the Modification and Creation date… - Apple Community


Apr 14, 2025 06:13 AM in response to RedJeryl

Here is a Bash shell script that when run in the Terminal, uses stat(1) to generate the following information with an absolute or tilde path to a file. This example was run on Sequoia v15.4. The PDF is user-locked.

odin: ~/Desktop % lsd.sh sig.pdf

-rwxr-xr-x* 6872 username staff sig.pdf 
 Inode: 487249 
 Link:  
 Flags: uchg 
 Last Access:        2025-04-05 13:17:37 
 Last Modify:        2024-04-30 14:18:31 
 Last inode change:  2025-02-01 12:26:12 
 Birth of inode:     2024-04-30 14:18:31


Copy and paste this into a programmer's editor (e.g. BBEdit) as plain text. Mine resides in ~/bin/lsd.sh and is marked executable with: chmod +x ~/bin/lsd.sh. I have prepended ${HOME}/bin to my PATH statement.


#!/bin/bash
#
# Syntax: http://www.real-world-systems.com/docs/stat.1.html
#    and: man stat
# See: stat(1), strftime(3)

for file in "$@"
do
    stat -t '%Y-%m-%d %X' -f '%n%Sp%T %z %Su %Sg %N %n Inode: %i %n Link: %SY %n Flags: %Sf %n Last Access:        %Sa %n Last Modify:        %Sm %n Last inode change:  %Sc %n Birth of inode:     %SB%n' "${file}"
done
exit 0


Apr 13, 2025 05:24 PM in response to Barney-15E

Barney-15E wrote:

When did file system date created become only metadata?


It’s a date and time that can change across various file systems and file system operations, and with less than entirely predictable results across a mix of platforms and operations.


UNIX doesn’t necessarily even have an equivalent, as an example. And where it does, the field name and details can vary. In POSIX, st_ctime tracks the inode creation date, which may or may not match what might be assumed for the file creation date.


Darwin (and macOS) extends the standard stat structure to include st_birthtimespec, which is how macOS does this.


This is part of why I’ve pointed at EXIF.

Apr 13, 2025 06:13 PM in response to Barney-15E

Barney-15E wrote:

This is part of why I’ve pointed at EXIF.

I didn’t think it was about content creation date. I thought the Author was asking about actual file creation date.
Or, are you telling me Unix doesn’t have a file system create date?


POSIX doesn’t have a file creation date. (POSIX is one of the standards upon which UNIX is built.)


Some UNIX systems do, such as macOS. Others may not or do not.


The inode creation date is the closest analog in POSIX, and that’s not exactly what most expect.


I’ve encountered far too many photographers piecemeal-building their own photo-management app constructs atop file system metadata, and discovering the fragility.


Again, use EXIF where you can, folks. You can even store your own custom info into that.

Apr 13, 2025 06:38 PM in response to RedJeryl

I guess I did not state my question clearly. I am a longtime Mac user too, and if I recall you could get info and see that a file (generally my files would be an Adobe design file of some kind) was created minutes, days or hours before and then show a modified date of the next time you saved the file. Am I missing something? I don't want to change a creation date, I want to see when I first made a file. My laptop shows the creation date and modification date as the same date and time for both. Thanks so much.

Apr 14, 2025 04:54 AM in response to RedJeryl

RedJeryl wrote:

I guess I did not state my question clearly. I am a longtime Mac user too, and if I recall you could get info and see that a file (generally my files would be an Adobe design file of some kind) was created minutes, days or hours before and then show a modified date of the next time you saved the file. Am I missing something? I don't want to change a creation date, I want to see when I first made a file. My laptop shows the creation date and modification date as the same date and time for both. Thanks so much.

Maybe you should o a Get Info on one of your files, take a screenshot, highlight where the missing information should be, and post it here. So far, nobody has any idea what you are talking about.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

What are the steps to restore file creation dates on Mac?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.