Gmail search operators are short commands, like from: or older_than:, that you type in Gmail's search bar to find exactly the emails you want. They're the fastest way to clean up, find old attachments and build filters.
On This Page
- How to Use Search Operators
- The Most Useful Operators
- Cleanup Recipes
- Finding Things Fast
- Advanced Operators for Power Users
- Search Recipes by Situation
- Searching on Your Phone
- Save Searches You Use Often
- Tips and Gotchas
- Search Operators vs Filters vs Labels
- From Search to Automation
- Gmail Search Operators FAQ
How to Use Search Operators
Type an operator and a value in the search bar, with no space after the colon: from:amazon.com. Combine several operators by putting spaces between them: from:amazon.com older_than:1y. Every search can become a filter with Create filter in the search options. See Gmail filters.
The Most Useful Operators
| Operator | What It Finds | Example |
|---|---|---|
from: |
Sender | from:[email protected] |
to: |
Recipient | to:me |
cc: / bcc: |
Copied recipients | cc:[email protected] |
subject: |
Words in the subject | subject:invoice |
" " |
Exact phrase | "quarterly report" |
OR or { } |
Either term | from:{alex sam} |
- |
Exclude a term | invoice -paid |
( ) |
Group terms | subject:(dinner movie) |
has:attachment |
Any attachment | has:attachment from:client.com |
filename: |
Attachment name or type | filename:pdf |
larger: / smaller: |
Size | larger:10M |
older_than: / newer_than: |
Relative age (d, m, y) | older_than:1y |
after: / before: |
Date range | after:2026/01/01 |
is:unread / is:starred |
Status | is:unread older_than:7d |
label: |
Labeled mail | label:receipts |
category: |
Inbox tab | category:promotions |
list: |
Mailing list | list:[email protected] |
in:anywhere |
Includes Spam and Trash | in:anywhere contract |
Cleanup Recipes
Copy these into Gmail's search bar, then select all matching conversations to delete or archive. See how to clean up your Gmail inbox.
Old Promotions
category:promotions older_than:6m
Big Emails
larger:10M older_than:1y
Unread Newsletters
is:unread unsubscribe older_than:1m catches most unread mailing-list mail
Old Notifications
category:updates older_than:3m
Video Attachments
has:attachment filename:mp4
Everything from One Sender
from:store.com
Finding Things Fast
- That contract from last spring:
from:lawyer.com filename:pdf after:2026/03/01 before:2026/06/01 - Emails waiting on you:
is:unread to:me -category:promotions - Messages you starred and forgot:
is:starred older_than:1m - Receipts for taxes:
subject:(receipt OR invoice) after:2026/01/01 - Everything with a specific person:
from:alex OR to:alex
Advanced Operators for Power Users
The basics cover most searches, but a few lesser-known operators solve specific problems.
| Operator | What It Finds | Example |
|---|---|---|
AROUND |
Words near each other | meeting AROUND 5 budget |
has:drive / has:document / has:spreadsheet / has:presentation |
Emails with Google Drive files | has:spreadsheet from:finance |
has:youtube |
Emails with YouTube links | has:youtube from:team |
has:userlabels / has:nouserlabels |
Labeled or unlabeled mail | has:nouserlabels older_than:1y |
deliveredto: |
Mail delivered to a specific address | deliveredto:[email protected] |
size: |
Mail larger than a size in bytes | size:5000000 |
+word |
An exact word, not variations | +unsubscribe |
is:important |
Mail Gmail marked important | is:important is:unread |
in:snoozed |
Snoozed conversations | in:snoozed |
header: |
A specific email header value | Used mainly for advanced filtering |
Combining Operators Without Surprises
Gmail treats a space between terms as AND. To mean OR, type OR in capitals or use curly braces. Parentheses group terms together, which matters when you mix AND and OR:
from:alex subject:(invoice OR receipt)finds Alex's emails whose subject has either word.from:{alex sam} has:attachmentfinds attachments from either person.-from:me is:unreadfinds unread mail you didn't send.
If a search returns nothing, remove one operator at a time to see which part is too narrow.
Date Searches That Actually Work
Absolute dates use YYYY/MM/DD. after:2026/01/01 before:2026/04/01 covers the first quarter. Relative dates use d, m or y, so newer_than:7d shows the last week and older_than:2y finds anything over two years old. Relative searches are handy in filters you reuse, because they always mean "from today."
Search Recipes by Situation
| You Want to Find | Search |
|---|---|
| Emails you sent that never got a reply | in:sent older_than:3d (then scan for missing replies) |
| Everything from your manager this month | from:[email protected] newer_than:1m |
| Big emails worth deleting | larger:20M |
| PDFs from a client | from:client.com filename:pdf |
| Calendar invitations | filename:ics |
| Unread mail outside Promotions | is:unread -category:promotions |
| Mail sent to an alias | deliveredto:[email protected] |
| Old starred messages to clean up | is:starred older_than:6m |
Cleaning Up with Search, Step by Step
Run the search and check the first page of results looks right.
Tick the select-all checkbox above the list.
Click "Select all conversations that match this search" to go beyond the first page.
Choose your action: Archive, Delete, Mark as read or apply a label.
Empty Trash afterward if you're freeing storage.
Always preview before bulk deleting. One extra word can turn a narrow search into a very broad one.
Why a Search Returns Nothing
- A space after the colon.
from: alexsearches for the word "alex" anywhere, not the sender. - The wrong address. Display names and email addresses differ; try just the domain.
- The mail is in Spam or Trash. Add
in:anywhere. - The date format. Use
YYYY/MM/DDwith slashes.
Searching on Your Phone
Most operators work in the Gmail app's search box too. Type them exactly as you would on a computer: from:bank.com has:attachment finds statements on your phone in seconds. The app doesn't show the search options panel, and filters still need a computer, so complex cleanup jobs are easier on desktop.
Save Searches You Use Often
Gmail doesn't have a "saved searches" button, but you have three good options:
- Bookmark the results page in your browser. Gmail puts the search in the address bar, so the bookmark reruns it.
- Turn the search into a label with a filter, so matching mail is collected automatically.
- Use Multiple Inboxes in Gmail settings, where each section can be a search, like
is:starredorlabel:waiting.
Tips and Gotchas
- No space after the colon.
from: alexwon't work as expected. - Negative operators work at the conversation level. Excluding something may still show a conversation if one message in it matches.
- Use the search options panel if you prefer forms to typing operators.
- Gmail search includes archived mail by default, but not Spam or Trash unless you add
in:anywhere.
Search Operators vs Filters vs Labels
These three tools work together:
| Tool | What It Does | When It Runs |
|---|---|---|
| Search operators | Find mail that matches criteria | When you search |
| Filters | Act on mail that matches criteria | When new mail arrives (or once on existing mail) |
| Labels | Tag mail so you can find or view it later | When applied by you or a filter |
A good workflow is to perfect a search first, then save it as a filter that applies a label. You get automation you trust, because you've already seen exactly what it matches.
From Search to Automation
Searches you run often are candidates for filters. A search like from:[email protected] can become a filter that skips the inbox and applies a label.
For the broader goal of keeping low-priority mail out of your inbox without dozens of searches and filters, SaneBox learns from your behavior and sorts automatically. See SaneBox for Gmail.
Spend Less Time Searching and Sorting
SaneBox keeps your Gmail inbox for important mail automatically. Try it free.
Gmail Search Operators FAQ
What are Gmail search operators?
Search operators are commands like from:, larger: and older_than: that narrow Gmail search results to exactly what you want.
How do I find large emails in Gmail?
Search larger:10M (or another size) to find emails above that size, often caused by attachments.
How do I search Gmail by date?
Use after:YYYY/MM/DD and before:YYYY/MM/DD for a range, or older_than: and newer_than: for relative dates.
Can I turn a Gmail search into a filter?
Yes. Open the search options panel after searching and click Create filter.
What does the minus sign do in Gmail search?
It excludes a term. For example, invoice -paid finds emails about invoices that don't mention "paid."
How do I search Gmail for unlabeled emails?
Search has:nouserlabels to find conversations without any of your labels, which is useful when tidying an archive.
Do Gmail search operators work in the mobile app?
Most do. Type them into the app's search box exactly as you would on a computer.
How do I select all search results in Gmail?
Tick the select-all checkbox, then click "Select all conversations that match this search" to include every result, not just the first page.
Why doesn't my Gmail search find an email I know exists?
Check for a space after the colon, try the sender's domain instead of their name and add in:anywhere to include Spam and Trash.