Including date and time in iPhone media filenames

Organizing iPhone photos often becomes a daunting task because of the default naming convention, particularly when dealing with sizable collections and attempting to locate images within specific timeframes.

This challenge becomes even more pronounced when a single destination folder accommodates content from diverse sources, including Android and iPhone devices. In such scenarios, creating a swift timeline-based slideshow using the default file manager can unexpectedly evolve into an extended configuration endeavor.

Numerous Android smartphone manufacturers use the “YYYYMMDD_hhmmss” format as their default naming convention. This approach aligns with my preferred structure as well. A quick fix could be bulk-renaming files through ExifTool, by adding the “CreateDate” metadata tag as part of the new filename.

The stand-alone Windows executable doesn’t require any installation. For command-line use, rename it to “exiftool.exe” and place it within the directory containing your iPhone media files (photos and/or videos).

The following command renames each file in the specified directory by using the “CreateDate” metadata tag as part of the new filename. The format of the new filename includes the date and time in the specified format (YYYYMMDD_hhmmss), followed by the original file name:

exiftool "-FileName<CreateDate" -d "%Y%m%d_%H%M%S-%%f.%%e" -r .

exiftool invokes the exiftool.exe application.

-FileName<CreateDate rename the files based on the “CreateDate” metadata tag and sets the new filename to the value of the specified tag.

-d "%Y%m%d_%H%M%S-%%f.%%e specifies the format of the new filename. The -d option is used to format the date and time; the %Y%m%d represents the year, month, and day; %H%M%S represents the hour, minute, and second; %%f represents the original file name; and %%e represents the original file extension.

-r . the r option tells ExifTool to process files recursively within the current directory ..

ExifTool Rename CMD Command
CMD output after performing the renaming command.

Example: IMG_0020.HEIC >> 20230511_165104-IMG_0020.HEIC

asterix Written by:

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *