Gmail offers a powerful search text field. You can use it with just normal keywords, or you can master the Gmail search syntax to really find what you are looking for in the least amount of time.
Some of these advanced search functions are available from the advanced search drop down box, but most are not.
Here are the top advanced search operators for Gmail
to: – Search for messages sent to a specific address.
from: – Search for messages sent from a specific address
subject: – Search the subject field.
label: – Search within a specific label.
has:attachment – Search only for messages that have attachments
is:chat – Search only chats.
in:anywhere – Also search for messages in the spam and trash. By default, Gmail’s search ignores messages in the spam and trash.
( ) – Brackets allow you to group search terms. For example, searching for subject:(how awesome) would only return messages with the words “how” and “awesome” in their subject field. If you search for subject:how awesome, you’d get messages with “how” in their subject and “awesome” anywhere in the message.
OR – OR, which must be in capital letters, allows you to search for one term or another. For example, subject:(how OR awesome) would return messages with the word “how” or the word “awesome” in their titles. You can also combine other terms with the OR. For example, from:example.com OR has:attachment would search for messages that are either from example.com or have attachments.
“ “ – Quotes allow you to search for an exact phrase, just like in Google. Searching for “exact phrase” only returns messages that contain the exact phrase. You can combine this with other operators. For example, subject:”exact phrase” only returns messages that have “exact phrase” in their subject field.
– – The hyphen, or minus sign, allows to search for messages that don’t contain a specific term. For example, search for -from:example.com and you’ll only see messages that aren’t from example.com.
list: – The list: operator allows you to search for messages on a mailing list. For example, list:firstname.lastname@example.org would return all messages on the email@example.com mailing list.
filename: – The filename: operator lets you search for a specific file attachment. For example, file:example.pdf would return emails with a file named example.pdf attached.
is:important, label:important – If you use Gmail’s priority inbox, you can use the is:important or label:important operators to search only important or unimportant emails.
has:yellow-star, has:red-star, has:green-check, etc. – If you use different types of stars (see the Stars section on Gmail’s general settings pane), you can search for messages with a specific type of star.
cc:, bcc: – The cc: and bcc: features let you search for messages where a specific address was carbon copied or blind carbon copied. For example,cc:firstname.lastname@example.org returns messages where email@example.com was carbon copied. You can’t use the bcc: operator to search for messages where you were blind carbon copied, only messages where you bcc’d other people.
deliveredto: – The deliveredto: operator looks for messages delivered to a specific address. For example, if you have multiple accounts in the same Gmail inbox, you can use this operator to find the messages sent to a specific address. Usedeliveredto:firstname.lastname@example.org to find messages delivered to email@example.com.