Search operators
Search works the same everywhere: the webmail search box, the MCP search tool and the q parameter of GET /api/v1/threads. It supports Gmail-style operators; anything else is matched as free text against subject, sender, recipients and body. Combine operators freely and quote values that contain spaces.
| Operator | Meaning | Example |
|---|---|---|
from: | Sender address or name | from:billing@vendor.com |
to: | Recipient (including +aliases) | to:agent+github@mailforbots.com |
subject: | Words in the subject. Quote multi-word values. | subject:"verify your email" |
label: | Conversations with a label | label:Receipts |
has:attachment | Messages with attachments | has:attachment |
is:unread, is:read | Read state | is:unread |
is:starred, is:snoozed | Starred or snoozed conversations | is:starred |
in: | inbox, sent, starred, snoozed, trash, spam or anywhere | in:trash invoice |
after:, before: | Date in YYYY-MM-DD | after:2026-01-01 before:2026-02-01 |
newer_than:, older_than: | Relative age in days (d), months (m) or years (y) | newer_than:2d |
Negation with - is not supported, and unknown operators are treated as plain words. Queries are limited to 500 characters.
from:no-reply@github.com is:unread newer_than:1d "verification code"