Batch copy filename to Title field? (In Mac Photos app)

I am looking for a way to automatically copy the file name of multiple photos to the Title field for a large number of photos. Is there a commercial utility or other way to do this? I would rather not copy and paste for 1000’s of photos!


Thanks

Mac Studio, macOS 15.0

Posted on Sep 21, 2024 12:40 PM

Reply
Question marked as Top-ranking reply

Posted on Sep 22, 2024 7:27 AM

I use  Photos Workbench($30) to set titles. It will certainly copy the filename there, but you get a lot more options:

Here I've added the date before the filename. It also does find and replace with titles, so I can fix my mistakes!

4 replies

Sep 21, 2024 2:14 PM in response to David Strait

I assume that AppleScript may be the best way to achieve this, but I'm dumb as a brick and don't know how to use AppleScript. I asked ChatGPT and it suggested the following:


-----

tell application "Photos"

set selectedPhotos to (get selection)

repeat with eachPhoto in selectedPhotos

set photoFilename to filename of eachPhoto

set title of eachPhoto to photoFilename

end repeat

end tell


-----


Got an error message which I sent back to Chat GPT and it gave me another script, which also failed. Did this three times in total before I gave up. Anybody have a suggestion how to correct this script, or another method to handle this?

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.

Batch copy filename to Title field? (In Mac Photos app)

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