Spotlight finds Notes via magnifying glass, but not via Finder “Find” or mdfind

notes.appsearchspotlight

I discovered that Spotlight can find my Notes if I just use the magnifying class icon in the main menu bar, but not if I open a Finder window and use command-F.

I've always assumed these were just two different ways of getting at Spotlight, using the same underlying data and engine. Is that completely wrong?

I was looking for something I wrote recently, and didn't remember whether it was text, a WP document, email, a note, or something else. So I opened a Finder window, hit command-F, switched to "Contents", and typed in a few words. Got lots of stuff, but not the file I wanted.

I tried many alternate words and phrases, limiting the search to my user area, limiting modification dates, etc. etc. — nothing.

Then I opened Notes and did a search there. Instantly found the right note.

So I copied a short phrase out, pasted it into the magnifying glass's searchbox. It found it just fine. Then I did command-F from a finder window again, and pasted it as a "Contents" search. Not found. I then reproduced the same problem with a different note and different search words.

I checked a bunch of things:

  • I tried words not in the first paragraph of the note, in case Spotlight considers that the "Name" rather than "Contents". No difference.

  • It doesn't matter whether I limit to my user area or not.

  • Nothing relevant is excluded via System Preferences / Spotlight / Privacy.

  • I wasn't trying to search for partial words.

  • I fiddled with mdfind, and it couldn't find the notes either.

  • The notes in question are not locked.

So, anybody know what the deal is with Find and Notes?

This is on a MacBookPro running High Sierra (10.13.6). Notes is Version 4.5 (876.1). It's syncing to my iCloud account, and that's the default for new notes.

Best Answer

The Notes app in macOS does not display notes as files on your computer regardless of whether they are synced to iCloud or not.

The Spotlight service is designed to display relevant information to a user by having access to all Apple apps (and most App Store apps) and their content. Notes does not store its content as a simple .txt or .rtf files so it gets its information by querying the app for the content you provide it. The app responds and Spotlight will open the app for you.

This database of content is rebuilt every time Spotlight indexes your computer. You can force Spotlight to re-index your machine by following the steps in this article: https://support.apple.com/en-gb/HT201716

Finder works differently as it will only search for physical files on your computer, meaning that notes will not show up.