The File Search command in Raycast uses the Spotlight index to retrieve results. It also requires the correct permissions to access some of your files and folders. If you’re having trouble finding files in File Search you can try some of the troubleshooting steps below.
If you can't find the files that you are looking for, you may not have granted access to some files and folders. The first time you open the File Search command, Raycast should prompt you to grant access to your files and folders.
You can check that Raycast has access to your files and folders in System Preferences → Security & Privacy → Privacy → Files and Folders.
Rebuilding Spotlight Index
In case both Spotlight and Raycast do not show expected results, Apple suggests to rebuild the Spotlight index by first adding and then removing folders via the Privacy tab under macOS Spotlight preferences. Try adding your home folder (or other folders where your files are located that you cannot find via Raycast) to the Privacy tab and removing it again. This is also described here: https://support.apple.com/en-us/HT201716
If that does not resolve the problem, you can try some commands on the terminal:
Spotlight Indexing (via Terminal)
You can check via the terminal if Spotlight indexing is enabled and in case it’s disabled, turn it on again:
Open a new Terminal window and enter:
This should print information about your volumes and whether indexing is enabled or disabled.
If you see a message that indexing is disabled, you can turn it off and on by entering and confirming with your admin password:
sudo mdutil -ai off sudo mdutil -ai on
After running those commands, it will take a while until all apps should start showing up again.
mdutil command available for rebuilding the index. The following command would trigger rebuilding the index on all volumes:
sudo mdutil -Ea
After running the command, make sure again that indexing is turned on via
mdutil -sa and wait some time. Then check again via both Spotlight and Raycast’s File Search.