Show file creation and modification dates with Get-Item
The three NTFS timestamps and how to read them all in one line of PowerShell.
01Command
$ Get-Item 'C:\Temp\report.xlsx' | Select-Object Name, CreationTime, LastWriteTime, LastAccessTime02What it does
LastWriteTime is what dir and Explorer show as 'Date modified'; CreationTime is when the file was created at this location, and LastAccessTime is often stale because Windows disables access-time updates by default for performance. The properties are settable, which is also how scripts normalize timestamps after a copy. Add -Force to include hidden and system files.
03Risk
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- Get-Item | Microsoft LearnEvidence: Microsoft documents Get-Item returning the object at a path, whose FileSystemInfo members include CreationTime, LastWriteTime, and LastAccessTime.
- Get-Item - PowerShellEvidence: SS64 describes Get-Item returning FileSystemInfo objects exposing the timestamp properties, including via .GetType() inspection.
Last verified: 2026-09-17 · Category: Files & Folders
06Related solutions
Diagnose NTFS file system errors and bad sectors on any volume — including the system drive while Windows is running — before committing to a repair.
Robocopy is Windows' built-in robust file copier: use /MIR to keep a destination folder as an exact one-way mirror of a source, resumable and restartable.
Search inside text files and logs with regex, returning file, line number and match.