Official reference documentation of Outlook search syntax?

Frank Macintosh 51 Reputation points
2023-02-03T18:02:14.37+00:00

I've asked about this before on answers.microsoft.com, but I've lost enough time on it that I think it's worth checking again, now that some time has passed.

I often use the Outlook email search bar (not the query builder) to assemble compound searches, e.g.,

body:(Alice AND Bob AND DesiredWord) AND (NOT "Don't want this phrase")

This does not work. It yields emails where "DesiredWord" is not in the body of the email message, but is in an attachment.

This cripples the usefulness of search in this day and age where everything is communicated in email messages, many of which have large documents attached. It decreases the signal-to-noise by many fold, if not orders of magnitude.

From various web searches, I've tried to find the right syntax for the "body:" specifier above. Some places refer to "contents:", but that doesn't work either, at least not for the compound arguments above.

What I asked before was whether there is an authoritative reference document for Outlook search syntax. Experimenting can consume huge portions of a working day, and I encounter this again and again. Is there still no such reference document? In this day and age when everything is electronic, this is debilitating. There must be a document somewhere, since the normal cycle of software development includes functional specification.

I'm looking for a reference that works for both Outlook desktop app and Office 365 webmail.

Outlook | Windows | Classic Outlook for Windows | For business
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. ChristyZhang-MSFT 26,186 Reputation points Microsoft External Staff
    2023-02-06T05:52:33.8233333+00:00

    Hi @Frank Macintosh ,

    Welcome to our forum!

    body:(Alice AND Bob AND DesiredWord) AND (NOT "Don't want this phrase")

    Based on my test on this condition, it works. Steps are as following:
    1.Cilck the Search bar > click the drop-down arrow > enter "(Alice AND Bob AND DesiredWord) AND (NOT "Don't want this phrase")" in the box after Body:

    5

    2.Select the appropriate range (e.g. I select the Current Folder) and click Search, then emails that match your criteria will then appear in the search list:

    6

    3.In addition, I added an attachment containing "(DesiredWord)" to the test email, which was not searched with the same search conditions.

    4.Considering that you may try to enter "body:(Alice AND Bob AND DesiredWord) AND (NOT "Don't want this phrase")" directly in Search bar, i tried too and get the correct search result.

    To further confirm if your issue is related to your current search settings, please try to change the scope of your search and check if there're any differences.

    On the basis of the above, it is recommended that you refer to this article and try to do some search-related troubleshooting: Outlook search returns incomplete results.

    Is there still no such reference document?

    As far as Outlook clients are concerned, there is an official document detailing how to use the Search feature: How to search in Outlook.

    Hope the above help!


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.