ClawdClaw ClawdClaw
← Back to blog
· 8 min

Gmail Filters: How to Create, Edit and Use Them (Step by Step)

Gmail filters explained step by step: create a filter from a sender, add a label, skip the inbox, edit, delete, import or export, and fix filters that fail.

Gmail filters are rules that act on incoming email for you: they can label a message, archive it, mark it as read, star it, forward it or delete it the moment it arrives. You create them from the search options panel in Gmail on a computer, and once saved they run on every new message that matches, on every device. This guide walks through each step, the criteria and operators you can use, ready-made examples and what to check when a filter does not work.

TL;DR

  • Create a filter: Show search options in the search bar, enter criteria, click Create filter, pick actions, save.
  • Manage filters in Settings, See all settings, Filters and Blocked Addresses: edit, delete, export or import them there.
  • Tick "Also apply filter to matching conversations" if you want the rule to touch email you already have.
  • Filters can only be created on a computer, but they keep working on your phone.

What a Gmail filter does

A filter has two halves: criteria (which messages it catches) and actions (what happens to them). Gmail checks each new incoming message against your filters and applies the actions automatically. If a filter has several criteria, a message has to meet all of them to match.

How to create a filter in Gmail (desktop)

  1. Open Gmail in a web browser on your computer.
  2. In the search bar at the top, click Show search options.
  3. Fill in your criteria, for example a sender in the From field.
  4. Click Search to preview which emails match. Adjust until the results look right.
  5. At the bottom of the search options window, click Create filter.
  6. Tick the actions you want.
  7. Click Create filter to save.

Google's own walkthrough is on the Gmail Help page for filters.

Create a filter from an existing email

  1. Tick the checkbox next to the email in your inbox.
  2. Click More.
  3. Choose Filter messages like these.
  4. Gmail pre-fills the criteria, usually with the sender. Edit them if needed, then click Create filter.
  5. Pick your actions and save.

The criteria fields

The search options panel gives you these fields:

  • From: sender address or name. You can enter a full address or just a domain, such as @example.com.
  • To: recipient address, useful for aliases or group addresses.
  • Subject: words in the subject line.
  • Has the words: words anywhere in the message, and also the place to type search operators.
  • Doesn't have: words that exclude a message.
  • Size: greater than or less than a size you choose.
  • Has attachment: only messages with attachments.

Gmail search operators that make filters smarter

Any query that works in the Gmail search bar can be typed into the "Has the words" field. These are the operators most useful for filtering, all taken from Google's list of Gmail search operators:

Operator What it does Example
from: Sender from:[email protected]
to: Recipient to:[email protected]
subject: Words in the subject subject:invoice
OR or { } Match either term from:amy OR from:david
- Exclude a word newsletter -unsubscribe
" " Exact phrase "order confirmation"
( ) Group terms subject:(invoice receipt)
has:attachment Has an attachment has:attachment from:accounting
filename: Attachment name or type filename:pdf
list: Mailing list address list:[email protected]
larger: / smaller: Size larger:10M
category: Inbox category category:promotions

Every action a filter can take

After you click Create filter, Gmail shows a list of checkboxes. You can tick as many as you like:

  • Skip the Inbox (Archive it): the message never appears in your inbox but stays in All Mail.
  • Mark as read: no unread badge.
  • Star it: adds a star.
  • Apply the label: pick an existing label or create a new one from the dropdown.
  • Forward it: send a copy to another address. The address has to be added and verified as a forwarding address first, in Settings under Forwarding and POP/IMAP.
  • Delete it: moves matching messages to Trash.
  • Never send it to Spam: keeps a trusted sender out of the Spam folder, the fix Google suggests for valid emails landing in Spam.
  • Always mark it as important or Never mark it as important: overrides Gmail's importance markers.
  • Categorize as: sends the message to a tab such as Primary, Social, Updates, Forums or Promotions.
  • Also apply filter to matching conversations: runs the filter on email already in your mailbox, not only new arrivals.

The classic: from sender, apply label, skip inbox

This combination is the most common filter people search for, and it gives you a folder-like setup:

  1. Show search options, enter the sender in From.
  2. Click Create filter.
  3. Tick Skip the Inbox (Archive it).
  4. Tick Apply the label and choose or create a label.
  5. Tick Also apply filter to matching conversations to clean up old messages too.
  6. Click Create filter.

Always pair Skip the Inbox with a label. Otherwise archived mail only lives in All Mail and is easy to lose track of.

Useful Gmail filter examples

Copy these into the "Has the words" field (or the field noted) and adapt them.

Newsletters out of the inbox Criteria: list:[email protected] or from:([email protected] OR [email protected]) Actions: Skip the Inbox, Apply the label "Reading".

Receipts and invoices in one place Criteria: subject:(receipt OR invoice OR "order confirmation") Actions: Apply the label "Receipts", optionally Skip the Inbox.

Never miss your boss or a key client Criteria: From [email protected] Actions: Star it, Always mark it as important, Never send it to Spam.

Forward invoices to your accountant Criteria: from:[email protected] has:attachment filename:pdf Actions: Forward it to your accountant's verified address, Apply the label "Invoices".

How to edit or delete a Gmail filter

  1. In Gmail, click Settings at the top right, then See all settings.
  2. Open the Filters and Blocked Addresses tab.
  3. Find the filter in the list.
  4. Click edit to change it, or delete to remove it.
  5. If editing, change the criteria, click Continue, adjust the actions, then click Update filter. If deleting, confirm with OK.

Deleting a filter does not undo what it already did. Labels stay on messages and archived email stays archived.

How to export and import Gmail filters

Export to back up your rules or copy them to another Gmail account.

Export

  1. Go to Settings, See all settings, Filters and Blocked Addresses.
  2. Tick the checkbox next to each filter you want (or select all).
  3. Click Export at the bottom of the list. Gmail downloads an .xml file you can open in any text editor.

Import

  1. In the other account, go to the same Filters and Blocked Addresses tab.
  2. Click Import filters at the bottom of the page.
  3. Choose the .xml file and click Open file.
  4. Click Create filters.

Gmail filters on mobile

Google is clear on this: to create a filter, you must open Gmail on a computer. The Gmail app on Android and iPhone does not let you create or manage filters.

Once a filter exists, it applies to incoming mail no matter where you read it, including the mobile app.

Why your Gmail filter is not working

Most broken filters come down to one of these:

  • It only affects new mail. Filters run on incoming messages. If you did not tick "Also apply filter to matching conversations", older email is untouched. Edit the filter and tick that box when saving.
  • Forwarding never applies to old mail. Google states that forwarding filters only affect new messages, even if you apply the filter to existing conversations.
  • The criteria are too narrow. Every criterion must match. A filter with both a From address and a subject word ignores messages from that sender with a different subject. Run the criteria as a search: if the search finds nothing, the filter will not either.
  • The sender changed address. Services often send from several addresses. Match on the domain (@example.com) or use list: instead of a single address.
  • Replies do not inherit the filter. A reply in a filtered thread is only filtered if it matches the same criteria on its own.
  • Typos in operators. Operators need a colon and no space after it: from:amy, not from: amy. OR must be in capitals.

FAQ

How do I create a filter in Gmail for a specific sender?

On a computer, click Show search options in the search bar, type the address in From, click Create filter, choose your actions and click Create filter again. You can also tick the email, open More and choose Filter messages like these.

Can Gmail filters move emails to a folder?

Gmail uses labels instead of folders. Combine Apply the label with Skip the Inbox (Archive it), and the message goes straight to that label without appearing in your inbox.

Do Gmail filters apply to existing emails?

Only if you tick "Also apply filter to matching conversations" when creating or updating the filter. Forwarding is the exception: it only ever applies to new messages.

Can I create Gmail filters on my phone?

No. Google says you must open Gmail on a computer to create a filter. Filters you create there still apply to mail you read in the mobile app.

How do I copy my Gmail filters to another account?

Export them from Filters and Blocked Addresses as an .xml file, then use Import filters in the other account's Filters and Blocked Addresses tab and click Create filters.

If you'd rather not do this yourself

Filters work well for predictable mail, but they cannot read a message and decide what it needs. ClawdClaw is a personal AI assistant powered by Claude from Anthropic that lives in your Telegram chat and can triage your Gmail, draft replies and follow-ups, and keep your Google Calendar in order. You sign up with Google, pair Telegram, and ask it in plain language.

Try ClawdClaw

Stop running your inbox. Hire ClawdClaw.

A personal AI assistant powered by OpenClaw, on Telegram. Email triage, follow-ups, research, scheduling — handled. Like a chief of staff who never sleeps.

Get started