Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

HighTime

macrumors regular
Original poster
Sep 20, 2014
131
5
Hey folks,

Is there a way to search for photos that are in the Photos app in Spotlight by name [and by extension in Alfred too]? As far as I can tell the photos are stored in the pictures folder but all I see is "Photos Library.photoslibrary" so if I search for a photo that I gave a particular name to it doesn't work.
 
  • Like
Reactions: gilby101

Rich B22

macrumors regular
Jul 24, 2019
113
58
Hey folks,

Is there a way to search for photos that are in the Photos app in Spotlight by name [and by extension in Alfred too]? As far as I can tell the photos are stored in the pictures folder but all I see is "Photos Library.photoslibrary" so if I search for a photo that I gave a particular name to it doesn't work.
That folder is where the images in the Photos App are stored. Did you happen to change the location, since if you do, it may not be selected as the System Photo Library, in which case, Spotlight will not search it.

If it has been moved, open the Photos App, click on Photos>Settings, then click on Use as System Library button. Depending on how large your folder is, it could take a very long time, plus, you'll have to reactivate iCloud photos for that library.

Good luck
 
  • Like
Reactions: HighTime

HighTime

macrumors regular
Original poster
Sep 20, 2014
131
5
That folder is where the images in the Photos App are stored. Did you happen to change the location, since if you do, it may not be selected as the System Photo Library, in which case, Spotlight will not search it.

If it has been moved, open the Photos App, click on Photos>Settings, then click on Use as System Library button. Depending on how large your folder is, it could take a very long time, plus, you'll have to reactivate iCloud photos for that library.

Good luck
Hey Rich, you know a few days when I was going through more setting on the Mac, I think I activated iCloud sync or something for documents etc just to check it out, later I decided I didn't want it and I can't remember what it did but it moved some of the folders or something like that and I think I went about trying to put things back, there's not much on there because I've only had it for two weeks, but I did end up wondering if the folders were in the same place as they were when I tried to sync.

Anyway, I did just check the Photos app and 'Use as System Photo Library' is faded out, so it seems as though it is already selected. I have literally only three photos in there at the moment, I renamed one of them and tried searching for it in spotlight and Alfred and it just doesn't show.
 

gilby101

macrumors 68030
Mar 17, 2010
2,950
1,632
Tasmania
Is there a way to search for photos that are in the Photos app in Spotlight by name [and by extension in Alfred too]?
Sort answer: No - not in Finder or Alfred, etc.

Longer answer: There are two types of Spotlight index.
  1. The one you are familiar with that indexes most of files in the file system. There is an index for each volume where Spotlight is enabled. These indexes are available to Finder, Alfred, HoudahSpot, etc. I call this "File system Spotlight" - I don't think there is an official name.
  2. "Core Spotlight" indexes which index the content of specific apps. These indexes are only available from their associated app and Command-Space Spotlight. These apps are Apple Apps like Notes, Mail, and Photos. They are not available for searching with Finder, Alfred, Houdah Spot, etc.).
This is the cause of much frustration and annoyance, as well as confusion.

The Command-Space Spotlight search provides answers from both Core Spotlight and file system Spotlight. So this type of search does include images from your Photos library, mail messages and Notes as well as those which are available to a Finder search.

I am not suggesting you do this, but if you were to export all your photos out of the Photos library and into a folder in the file system, the photos would be indexed by "File system Spotlight" and the results are available to Finder, Alfred, etc.
 
  • Like
Reactions: HighTime

HighTime

macrumors regular
Original poster
Sep 20, 2014
131
5
Sort answer: No - not in Finder or Alfred, etc.

Longer answer: There are two types of Spotlight index.
  1. The one you are familiar with that indexes most of files in the file system. There is an index for each volume where Spotlight is enabled. These indexes are available to Finder, Alfred, HoudahSpot, etc. I call this "File system Spotlight" - I don't think there is an official name.
  2. "Core Spotlight" indexes which index the content of specific apps. These indexes are only available from their associated app and Command-Space Spotlight. These apps are Apple Apps like Notes, Mail, and Photos. They are not available for searching with Finder, Alfred, Houdah Spot, etc.).
This is the cause of much frustration and annoyance, as well as confusion.

The Command-Space Spotlight search provides answers from both Core Spotlight and file system Spotlight. So this type of search does include images from your Photos library, mail messages and Notes as well as those which are available to a Finder search.

I am not suggesting you do this, but if you were to export all your photos out of the Photos library and into a folder in the file system, the photos would be indexed by "File system Spotlight" and the results are available to Finder, Alfred, etc.
Many thanks for the clear explanation. I have virtually nothing in the Photos library since it's a new machine, I may as well create a separate folder for all the pics so they can be indexed.
 

RhetTbull

macrumors member
Apr 18, 2022
99
73
Los Angeles, CA
...

I am not suggesting you do this, but if you were to export all your photos out of the Photos library and into a folder in the file system, the photos would be indexed by "File system Spotlight" and the results are available to Finder, Alfred, etc.
I'm the author of the free / open source tool osxphotos which provides several utilities for working with Photos libraries including a robust export tool. All modern Mac use the APFS file system for their internal disks and APFS supports something call "copy on write" which means that a copy of file onto the same disk takes no additional disk space (until the file is modified, at which time a copy is made). If on an APFS volume osxphotos will make use of this when exporting. Thus you could export all your photos from Photos to another folder and the images would all be fully searchable with Spotlight and wouldn't require any additional space. As a bonus, if you use Time Machine this is a way to get a full backup of your photos outside the Photos ecosystem as Time Machine will see these as separate files and happily back them up. I do this to backup my library to Time Machine and Backblaze without using any extra space on the internal volume.
 
Last edited:
  • Like
Reactions: gilby101
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.