Apple Mail Search Not Working? How to Fix It
Apple Mail search not working? Fix it in order: check Spotlight privacy, rebuild the mailbox, reindex Mail's Envelope Index, then reindex Spotlight.
TroubleshootingUpdated 8 min read
On this page
When Apple Mail search is not working, the cause is usually one of two things: Mail's own index is out of date, or Mail's data is excluded from Spotlight. Start by checking Spotlight's privacy list. Then select the mailbox and choose Mailbox ▸ Rebuild. If search is still broken, quit Mail and let it rebuild its Envelope Index.
The fixes below go from quickest to most thorough. Stop as soon as search works again.
Why Apple Mail search stops working
Mail doesn't read through every message each time you search. It relies on two indexes:
- Mail's own database, called the Envelope Index. It records which messages are in which mailbox, along with senders and subjects.
- Spotlight, the system-wide search index, which Mail uses to search message content.
If either index is damaged, incomplete or switched off, results come back empty or partial. Common triggers:
- A macOS upgrade
- An interrupted import or migration
- A disk that filled up while Mail was writing
- A Spotlight exclusion someone added long ago and forgot
Before you change anything, run a quick test. Press ⌘Space (Command-Space) and search Spotlight for the exact subject of an email you know exists.
- Spotlight finds the email but Mail doesn't: the problem is most likely Mail's own index. Rebuild the mailbox, then reindex the Envelope Index.
- Neither finds it: start with the Spotlight checks.
If you haven't restarted your Mac recently, do that first. It's quick and sometimes clears a stuck index.
| Fix | What it resets | Typical time cost | Risk |
|---|---|---|---|
| Check Spotlight exclusions | Nothing, unless you remove an exclusion | A couple of minutes, then background indexing | None |
| Rebuild a mailbox | One mailbox's messages and index entries | Minutes per mailbox; longer for large IMAP mailboxes that re-download | Low |
| Reindex the Envelope Index | Mail's whole database | Minutes to hours, depending on how much mail you have | Low if you keep the moved files as a backup |
| Reindex Spotlight | The search index for the whole disk | Often hours; search is incomplete until it finishes | Low |
Check that Mail isn't excluded from Spotlight
If your startup disk, your home folder or a Library folder is on Spotlight's privacy list, Mail search can come back empty or partial.
- Open System Settings.
- Type "Spotlight" in the search field at the top of the sidebar, then open the Spotlight settings.
- Click the privacy button. Depending on your macOS version, it's labeled Spotlight Privacy… or Search Privacy….
- Look through the list for your startup disk (usually Macintosh HD), your home folder, a Library folder or any Mail folder.
- If you find one, select it and click the remove button (−).
- Click Done.
Some versions also list the categories Spotlight shows in results. If yours does, turn Mail & Messages on while you test. It's an easy setting to rule out.
Removing an exclusion makes Spotlight index that location from scratch. Give it time, ideally with your Mac plugged in, before deciding the fix didn't work.
Rebuild the affected mailbox
Rebuilding makes Mail re-read one mailbox and refresh its index entries. Use it when search fails in one mailbox but works elsewhere, or when specific messages are missing from results.
- Open Mail.
- In the sidebar, select the mailbox that searches badly (for example, an account's Inbox or Archive).
- Choose Mailbox ▸ Rebuild from the menu bar.
- Wait until the mailbox finishes reloading, then search again.
What it costs:
- IMAP accounts (iCloud, Gmail, most others): Mail downloads the mailbox's messages again from the server. A large mailbox takes a while and uses bandwidth, and messages may be missing from the list until the download finishes.
- Local mailboxes (under On My Mac): Mail re-reads the files already on your disk, so it's usually faster.
Rebuild one mailbox at a time. If you rebuild several together, you can't tell which one fixed the problem.
Reindex Mail's Envelope Index
If rebuilding mailboxes doesn't help, or search is broken across every account, make Mail build its database again. Your messages stay where they are. Only the index is recreated from them.
If you keep mail in On My Mac mailboxes, back up with Time Machine first. Those messages exist only on your Mac.
- Quit Mail with ⌘Q (Command-Q). Make sure it's fully closed.
- In Finder, choose Go ▸ Go to Folder… (⇧⌘G, Shift-Command-G).
- Type
~/Library/Mailand press Return. - Open the folder named
Vplus a number, such asV10. If you see more than one, open the one with the highest number. - Open the
MailDatafolder. - Make a new folder on your Desktop, for example
Envelope backup. - Drag every file whose name starts with
Envelope Indexinto that folder. There are usually three:Envelope Index,Envelope Index-shmandEnvelope Index-wal. - Open Mail. It rebuilds the index from your messages. Leave it open until it finishes.
This can take anywhere from a few minutes to several hours, depending on how much mail you have. Mail may be slow and use a lot of CPU while it works. A damaged Envelope Index can also make Mail sluggish, so this fix sometimes helps if Apple Mail is slow too.
To undo:
- Quit Mail.
- Drag the files from
Envelope backupback intoMailData, replacing the new ones.
Once search works and nothing looks missing for a few days, you can delete the backup folder.
Reindex Spotlight for the whole disk
Do this when Spotlight itself misses files and emails, or when the earlier fixes didn't help. It rebuilds the search index for your entire startup disk. On a full disk that often takes hours, and both Spotlight and Mail search stay incomplete until it's done.
Using System Settings
- Open the Spotlight privacy list as described above.
- Click the add button (+), choose your startup disk (usually Macintosh HD) and add it.
- Wait a few seconds, then select it and click the remove button (−).
- Click Done. Spotlight starts indexing the whole disk again.
Using Terminal
Check whether indexing is turned on for your startup disk:
mdutil -s /This only reports status. It should say "Indexing enabled."
If it reports that indexing is disabled, turn it back on:
sudo mdutil -i on /This re-enables Spotlight indexing on the startup disk, which is the normal macOS setting. To reverse it, run the same command with off in place of on (not recommended).
The next command deletes the current Spotlight index. Search across your Mac is incomplete until the rebuild finishes.
sudo mdutil -E /This erases the Spotlight index for the startup disk and makes macOS build a fresh one. There's nothing to undo: the new index replaces the old one once indexing finishes. Both sudo commands ask for your Mac's login password.
Leave your Mac awake and plugged in while it indexes.
What if search still misses older mail
If search works for recent messages but not older ones, the indexes may be fine. Check these causes.
The search scope is set to one mailbox. When you search, Mail shows where it's searching in the Favorites bar above the message list. Choose All instead of the current mailbox.
Trash and Junk are left out. In Mail, open Mail ▸ Settings ▸ General and find the options that include results from Trash and Junk when searching all mailboxes. Turn them on if the mail you want might be there.
The mail was never downloaded. Mail can only index messages it has synced. Check that:
- The account is turned on for Mail (in Mail's Accounts settings, or in Internet Accounts in System Settings).
- The mailbox actually shows the older messages when you scroll down.
If a mailbox stops partway, rebuild it.
Gmail is limiting what Mail sees. Gmail controls which labels and how many messages appear over IMAP. In Gmail on the web, open Settings ▸ See all settings, then check:
- Forwarding and POP/IMAP ▸ Folder size limits: leave it unlimited if you want everything in Mail.
- The Labels tab: All Mail and the labels you search should have Show in IMAP ticked.
The mail lives in an old local archive. Mailboxes under On My Mac that came from another Mac are only indexed after Mail has read them. Rebuild each one.
Is there a mail app with its own search index
For most people, Apple Mail is enough once its index is healthy, and it's free. If search keeps breaking after macOS upgrades, or you'd rather not depend on Spotlight, a mail app that keeps its own index is an alternative.
We make Mailloft, which works that way. Its search doesn't use Spotlight:
- Local index first. It searches a full-text index kept in Mailloft's own folder, across every account at once. That covers sender, recipients, subject, preview text, the body of messages you've opened, and attachment names. It shows up to 1,000 local results, newest first.
- Then your servers. About half a second later, it also searches each account's server and lists those hits under From Your Servers. That finds mail that was never downloaded, with limits: up to 4 folders per account and 50 hits per folder.
- Search operators. You can type:
from:,to:,subject:has:attachment,is:unreadbefore:2025-06,after:yesterdayin:sent,account:"exact phrase", or-wordto exclude a word
Open search from the toolbar search field, with ⌥⌘F (Option-Command-F), or by pressing / in the default key preset.
The trade-offs:
- Message bodies are indexed only after you open them. Mailloft syncs the newest 200 messages per mailbox and loads older ones as you scroll, so server search is what finds very old mail.
- Chinese, Japanese and Korean words only match from their start.
- Mailloft works with IMAP accounts only.
- Gmail and Google Workspace accounts need an app password; there's no "Sign in with Google".
The Mailloft search docs list every operator. Mailloft is part of MacSuite; you can try it free for 7 days.
If you're comparing other options, see our Apple Mail alternatives and best email clients for Mac.
When to contact Apple Support
If search is still broken after you've rebuilt the mailbox, reindexed the Envelope Index and let Spotlight finish a full reindex, contact Apple Support. Tell them:
- Your macOS version
- Which account types are affected (iCloud, Gmail, Exchange, On My Mac)
- Whether Spotlight finds the same emails outside Mail
- Which fixes you've already tried
That way you won't be asked to repeat the steps above.