Gmail Search Operators

Last updated on July 31, 2021.

Here is the list of 50+ Gmail advanced search operators with specific examples and some extra search tips for Gmail. 

Gmail search operators are special commands that let you refine and filter your Gmail search results. Thanks to them, you can easily find a specific email or group of emails you are looking for. 

Knowing how Gmail search works and how to use its search operators is indeed a very useful skill to have. That’s why I compiled this list! Gmail search operators work similarly to Google search operators.

How To Use Search Operators In Gmail 

To put any Gmail search operator into action, you need to do:

  • Go to your Gmail account (in the web browser).
  • Type the search operator or operators in the Gmail search box. 
  • Hit enter. 
  • That’s it!
Gmail search box where you type the search operator

Gmail Advanced Search Operators In Action

Below is the list of 50+ Gmail search operators together with the explanation of their function, example use, and the screenshot from my Gmail inbox.  

The chances are you are also an active user of other Google services, so will probably also be interested in learning about YouTube search operators and Google Drive search operators.

SEO NEWSLETTER

Subscribe to receive free weekly updates with SEO news, SEO tips, SEO tools, and more!
Join 3000+ ambitious SEOs.

1. Filter By The Sender

This search operator lets you search for emails from a specific sender. Make sure not to put any spaces after or before the colon.

from:
Example: from:olga

2. Filter By The Recipient

This Gmail search operator will return emails sent to a specific recipient. 

to:
Example: to:olga

Gmail search operators: A Gmail search operator that allows for filtering by the recipient typed in the Gmail search box

3. Filter By The Recipient With A Copy 

This Gmail search operator lets you filter by specific recipients who received a copy.  

cc:
bcc:

Example: cc:olga

Gmail search operators:  A search operator for filtering by the recipients who received a copy typed in the Gmail search box

4. Filter By The Words Used In The Subject Line 

Use this to look for emails that have specific phrases in the subject line. 

subject:
Example: subject:seo

Gmail search operators: A search operator searching for messages with specific phrases in the subject line typed in the Gmail search box.

5. Filter By Multiple Keywords 

This search operator will return results with references to either one or another keyword. Make sure not to use square brackets.

( )
Example: (seo sem)

Gmail search operators: A search parameter for filtering by multiple keywords typed into the search box in Gmail

6. Filter By An Exact Phrase

Use this if you want to find emails that contain the exact phrase. 

" "
Example: "seo audit"

A search operator for filtering by an exact phrase typed into the search box in Gmail.

This is very useful if you remember a certain phrase but want to find the message that contains it. To find this message, you simply need to put the phrase in quotes. It works the same in Google search.

7. Filter Emails By The Folder

Instead of manually switching between folders in your Gmail inbox, you can just use the in: search operator to search for messages in a specific folder. 

in: 
Example: in:spam

Gmail search operators: A search parameter for filtering emails by the folder typed into the Gmail search box

It may come useful if you want to look for a specific email in a specific folder. Just type your query and add in: to search only this specific folder. 

8. Find Emails With An Exact Word Match

This will return emails with an exact word match to what you typed after +. Remember not to put any spacer after +.

+
Example:+seosly

Gmail search operators: A search parameter for filtering emails with an exact word match typed into the Gmail search box

9. Find Emails With A Certain Label

This search operator lets you filter emails by their label. It may be very useful if you’re using the same email address both for work and personal use.

label: 
Example: label:work

Gmail search operators: A search operator for searching for emails with a specific label typed into the Gmail search box

To display only work-related messages, you just need to type label:work. This, of course, will work only if you label your work emails. Type any label name you have to find the emails with that label.

10. Find Emails That Have Words Near Each Other

This search operator lets you specify how many words apart the phrases should be. 

AROUND
Example: seo AROUND 20 audit

Gmail search operators: A search operator for finding messages that have certain words near each other typed into the Gmail search box

In the example above my search will return the messages which contain word “seo” and word “audit” that is not more than 20 words apart from “seo”. 

11. Find Emails Without A Specific Phrase In The Subject Line 

This Gmail operator allows for searching for messages with a certain keyword but with the exclusion of another keyword. You can also simply use the exclusion rule a type subject(-seo).

subject:( )
Example: subject:(seo -audit)

Gmail search operators: A search operator for finding messages that without a specific word in the subject line typed into the Gmail search box

This one seems to be working just fine without ( ) as well, so you might just use subject:-seo. Don’t put any spacer after or before the colon.

12. Find Emails In Any Folder 

This search operator also applies to messages in the Spam and Thrash folders. Use this to search all of your Gmail. 

in:anywhere
Example: in:anywhere

A search operator for finding messages in any folder typed into the Gmail search box

If you want to find messages with a specific keyword in any folder, just type seo in:anywhere. If you just type a keyword without specifying the folder the effect will be the same as if you used this operator. This one is more for educational purposes.

13. Find Emails Marked As Important 

This Gmail operator lets you find messages that are marked as important. Note that Gmail may mark some emails as important even if you don’t really think they are. In most cases, however, Gmail correctly recognizes important emails.

is:important
label:important 
Example: is:important

Gmail search operators: A search operator for finding messages labelled as important typed into the Gmail search box

14. Find Emails In A Specific Category 

This Gmail search operator allows you to search for messages in a specific category. 

category:primary
category:social
category:promotions
category:updates
category:forums
category:reservations
category:purchases

Example: category:updates

Gmail search operators: A search operator for finding messages in a specific category typed into the Gmail search box

To find messages with the word “seo” in the primary category type seo category:primary.

15. Find Starred Emails

Use this operator to search for starred emails. This will look for the important emails that were marked as important by you (i.e. starred).

is:starred
Example: is:starred

A search command for finding starred messages typed into the Gmail search box

16. Find Unread Emails

Use this operator to find only unread emails. Awesome for checking if you have not missed some emails.

is:unread
Example: is:unread

Gmail search operators: A search operator for finding unread messages typed into the Gmail search box

17. Find Read Emails 

This Gmail operator does the contrary. It lets you search for emails that are marked as unread. 

is:read
Example: is:read

Gmail search operators: A search command for finding read messages typed into the Gmail search box

18. Find Snoozed Emails 

This operator is for finding snoozed messages. This is again a very useful way to check if you have not snoozed some important email and forgotten about it.

in:snoozed
Example: in:snoozed

Gmail search operators: A search operator for finding messages that have been snoozed typed into the Gmail search box

19. Search For Emails With Or Without A Label

This Gmail parameter will display only the messages that have labels. These are only the labels created by you, not automatic system labels like Starred, Snoozed, etc.

has:userlabels
Example: has:userlabels

A search operator for finding messages with a user label typed into the Gmail search box

And this operator does the exact opposite. Remember that labels are only added to a specific message (not the entire conversation).

has:nouserlabels
Example: has:nouserlabels

Gmail search operators: A search operator for finding messages without a user label typed into the Gmail search box

20. Find Emails Sent In A Certain Time Frame

If you have tons of messages, this Gmail search operator will help you narrow down the results to a specific time frame.  If you receive a lot of emails, this can be a huge time saver.

after:
before:
older:
newer:

Example: before:2020/07/15

A search operator for finding messages sent after a certain date typed into the Gmail search box

Example: after:07/15/2020

A search operator for finding messages sent before a certain date typed into the Gmail search box

21. Find Emails That Are Newer/Older Than A Certain Time Frame 

This Gmail operator works similarly except that here you can define a time period instead of a time frame. You can specify a day (d), month (m), and year (y). Sometimes simply defining a time period is quicker and easier.

older_than:
newer_than:

Example:newer_than:6m

Gmail search operators: A search parameter for finding messages that are newer than 6 months typed into the Gmail search box

22. Find Emails Delivered To A Specific Address

The recipient e-mail address you type in the recipient field isn’t always the actual or the only e-mail address that the e-mail will be delivered to. 

That’s where this search operator comes in very handy. It helps you find messages that were delivered to a specific email address. 

deliveredto:
Example: deliveredto:olga@seosly.com

Gmail search operators: A search operator for finding messages delivered to a specific address typed into the Gmail search box

23. Find Chat Messages

If you’re still using Gmail chat, this operator lets you search chat messages. 

in:chats
Example: in:chats seo

A Gmail search operator for finding chat messages with a certain keyword typed into the Gmail search box

25. Find Emails From A Mailing List

This command lets you display messages from a particular mailing list. This is most useful for work emails. 

list: 
Example: list:news@seosly.com

Gmail search operators: A Gmail search operator for finding messages from a specific mailing list typed into the Gmail search box

26. Find Emails That Have A Certain Icon

If these certain icons have been used in some of your emails, then this operator will help you find these messages.

has:yellow-star
has:blue-info
has:green-check

Example: has:yellow-star

A Gmail search operator for finding messages that have a certain icon typed into the Gmail search box

Note that has:yellow-star works like in:starred. It simply displays starred messages.

How To Search For Mails With Attachments 

Any message that has an attachment has this clip icon on the right side (like on the screenshot below).

A message in Gmail with an attachment

Sometimes, however, that’s not enough to find the email you are looking for. Here are a few ways to refine Gmail search results that contain attachments. 

27. Find Emails With Attachments

Use this operator to display only the messages that have attachments. 

has:attachment
Example: has:attachment

Gmail search operators: A Gmail search operator for searching for emails with attachments.

Note that if you have mails with various attachments in your Gmail inbox you will see some suggested attachment types once you type has:attachments.

The suggested attachment types in Gmail search

This will make finding specific attachments way easier.

28. Find Emails With Attachments From Drive/Docs/Sheets/Slides

This Gmail operator will search for emails that include a Google Drive, Google Doc, Google Sheet, or Google Slide attachment. 

has: drive
has: document
has: spreadsheet
has: presentation

Example: has:document

Gmail search operators: : A Gmail search operator for finding emails with attachments from Google Drive, Google Docs, Google Sheets, or Google Slides typed into the Gmail search box

This is very useful as more and more people are switching to online documents instead of sending documents as attachments. 

29. Find Emails With A Certain File Name Or Type Attached

This Gmail search operator will display the messages with a specific file or file type attached. 

filename:
Example: filename:pdf
Example: filename:robots.txt

Gmail search operators: A Gmail search operator for finding emails with a certain document type attached typed into the Gmail search box

30. Find Emails With A YouTube Video Attached

Use this to display emails that have links to YouTube videos. So useful if your friends or collegues like to share videos with you through email.

has:youtube
Example: has:youtube

Gmail search operators: A Gmail search operator for finding emails with YouTube videos typed into the Gmail search box

31. Find Emails That Are Above A Certain Size 

This command will help you specify the message size in bytes. In most cases, you will use it to search for emails with specific attachments. 

size:
Example: size:1000000

Gmail search operators: A Gmail search operator for finding emails above a certain size typed into the Gmail search box

32. Find Emails That Are Above Or Below A Certain Size

This one is quite similar as it lets you specify a maximum or minimum size of the message.  

larger:
smaller:

Example: larger:10M

A Gmail search operator for finding emails below a certain size typed into the Gmail search box

How To Combine Search Operators 

You can combine search operators to perform advanced searches in Gmail and refine your searches even more. 

You can also use Boolean operators like AND, OR, NOT, or AND NOT in your Gmail searches just like in Google search. More about it later.

33. Find Messages Matching Multiple Terms

This search command will display messages from either “olga” or from “tom”. Welcome to Gmail advanced search!

OR or { }
Example: from:olga OR from:tom
Example: (from:olga from:tom}

A Gmail search operator for finding emails matching multiple terms typed into the Gmail search box

34. Find Messages By Grouping Multiple Words/Terms Together

With the help of this Gmail search operator, you can look for messages by grouping multiple words together.

( )
Example: subject:(seo help)

Gmail search operators: A search operator for finding emails by grouping multiple terms together typed into the Gmail search box

35. Find Snoozed, Starred, Unread, Or Read Emails

This operator lets you search for emails from multiple groups.

is:snoozed
is:starred
is:unread
is:read

Example: is:read is:starred

Gmail search operators: A Gmail search operator for finding emails that are snoozed, starred, unread or read typed into the Gmail search box

You can combine is:read with is:starred but don’t combine mutually-inclusive operators like is:read and is:unread.

36. How To Remove Mails From Gmail Search Results

This search operator will exclude the messages that contain a specific term. It works the same way in Google the search engine.

-
Example: seo -sitemap

A Gmail search command for excluding emails containing a specific term typed into the Gmail search box

How To Use Boolean Operators In Gmail Search

You can use the Boolean operators, such as AND, OR, NOT, or AND NOT to refine your searches in Gmail in yet another way.

37. Search For Messages That Meet Multiple Criteria

This Gmail command will display emails that contain words “seosly” and “backup”. Obviously, these are going to be emails with information about the backup of my site.

AND
Example: "seosly" AND "backup"

Gmail search operators: Boolean operator AND used in Gmail search

38. Search For Messages That Meet One Or Two Criteria

This search command will display messages that are from WordPress or from Coursera, or both.

OR
Example: from:wordpress OR from:coursera

Gmail search operators: Boolean operator OR used in Gmail search

39. Exclude Messages That Meet Certain Criteria

NOT
Example: NOT from:wordpress

Gmail search operators: Boolean operator NOT used in Gmail search

40. Search For Messages That Meet One Criterium And Exclude Messages Meeting Other Criterium

This search command will display messages that are marked as important and have not been read.

AND NOT
Example: in:important AND NOT in:read

Boolean operator AND NOT used in Gmail search

Gmail Search Operator Real-Life Examples

Here are some of my favorite advanced uses and combinations of Gmail search operators to refine the Gmail search even further.  

It’s very easy to combine different Gmail search operators. You simply use them one after another in any order you want just making sure not to make any typos or extra spaces.

41. Search For A PDF SEO Audit That Olga Sent Me

This one will search for emails from Olga that have the phrase “seo audit” in the subject line and contain a PDF file attached. This is a way to look for SEO audit PDF files Olga sent.

from:olga subject:("seo audit") filename:pdf

Example of using multiple advanced Gmail search operators

42. Search For A PDF SEO Audit That Olga Sent Within A Month

Here I refined the search even further so that I can only see the SEO PDF audits sent by Olga within the last month.

from:olga subject:("seo audit") filename:pdf newer_than:1m

Example of using multiple advanced Gmail search operators

43. Search For All The Messages With Attachments From Olga

With this search I can see all the emails from Olga which as “seo” in the subject line and have an attachment.

from:olga subject:(seo) has:attachment

Example of using multiple advanced Gmail search operators

44. Search For Messages From Olga That Contain A YouTube Video And Word “seo”

This will let me display all the messages with YouTube videos about SEO that Olga sent me.

from:olga has:youtube +seo

Example of using multiple advanced Gmail search operators

45. Search For Messages I Sent With A Google Doc Attached & Phrase “seo audit” In Subject Line

This command will display all the messages I sent which contain “seo audit” in the subject line and have a Google Document attached.

from:me has:document subject:"seo audit"

Example of using multiple advanced Gmail search operators

46. Search For Unread Messages From Olga With A Google Slide Attached & Containing Word “SEO”

This command will display all the messages from Olga with a Google Spreadsheet attached and containing word “seo”.

from:olga is:unread has:presentation +seo

Example of using multiple advanced Gmail search operators

47. Search For The Emails I Sent And Which Have A Google Doc And A Google Spreadsheet Attached

Here I can see the messages I sent which have both a Google Doc and a Google Spreadsheet.

from:me has:document AND has:spreadsheet

Example of using multiple advanced Gmail search operators

48. Check What Labels You Have In Your Gmail

label:

A search command that will display all the labels available in your Gmail.

Type label: and you will see all the labels available in your Gmail.

49. Check What Categories You Have In Your Gmail

If you are not sure what categories you have in your Gmail inbox, here is a quick way to check that.

category:

A search command that will display all the categories available in your Gmail.

Type category: to find what categories you have

50. Create Your Own Gmail Search Filters 

If you tend to do similar Gmail searches over and over, it may be a good idea to create your own Gmail search filter. To create a custom Gmail search filter: 

  • Click on the arrow down in the Gmail search box.
Gmail search operators
  • Specify what you want/don’t want to include in your searches.
Creating an advanced search filter in Gmail
  • Click on Create filter and OK and you are all set up. 
Creating an advanced search filter in Gmail and confirming

Now in the Gmail search box, I can see how my filter looks like when “translated” into Gmail search operators.

Advanced Gmail filter in the Gmail search box

There is also an article about search operators in the Gmail Help.

FAQs On Gmail Search Operators

Some of the below content may be overlapping because this is the complete list of Gmail search operators. However, as so many people as these questions about Gmail search, I am answering them all there in this section.

How can I search for unread emails in Gmail?

Just type is:unread in the top search box in Gmail. This will return the list of unread emails in your Gmail inbox. If you want to narrow down your searches, you can combine this Gmail search operator with keywords or keywords in quotes (to force an exact match) like is:unread "seo audit".

How do I search for an email in Gmail?

To search for an email in Gmail you simply need to use the search box on top of your Gmail inbox. Click on the drop-down arrow to the right side of the search box to unfold advanced Gmail search options like searching by the sender, subject, keywords, and more.

How do I search Gmail by sender?

In the search box on the top of your Gmail inbox, type from: and then the e-mail address of the sender or their name. Gmail will be suggesting senders once you start typing. You can also click on the arrow down on the right to unfold Gmail advanced features and type the sender name there.

How do I search for labels in Gmail?

To search for labels in Gmail simply type label: and then label name in the top search bar in your Gmail mailbox. To search for emails labeled as “work”, simply type label:work. To search for an email with user labels, type has:userlabels.

How can I view all unread emails in Gmail?

To view all unread emails in Gmail type is:unread in the Gmail search box at the top and hit enter.

How do I see all emails from one person in Gmail?

To see all emails from one person in Gmail, simply type from: and then type their e-mail address or name. Gmail will start autocompleting senders once you start typing based on your emails and contact list.

Can you search Gmail by date?

Yes, you can search Gmail by date. To search for emails after a certain date, simply type after:mm/dd/yyyy in the top search box in your Gmail inbox. To search for emails before a certain date type before:mm/dd/yyyy.

GET ACCESS TO PREMIUM SEO CONTENT

Members of SEOSLY Pro get access to Olga’s SEO audit video guide where she documents her 500+ step SEO audit process, Olga’s mini video SEO audits, SEO audit templates, pro SEO auditing tips, and much more!

Join SEOSLY Pro to become a technical SEO expert in no time.

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *