You can automatically label emails in Gmail with a native filter when the match is exact. If the label depends on the meaning of the message, use an AI rule and review its results before adding any archive action.

Method 1: Use a Gmail filter

This method is free and works well for a known sender, mailing list, subject phrase, recipient address, or attachment type.

  1. Open Gmail on a computer.
  2. Click the search-options icon at the right side of the search bar.
  3. Enter your criteria, such as from:billing@example.com.
  4. Click Search first and inspect the results.
  5. Open the search options again and click Create filter.
  6. Select Apply the label, then choose or create a label.
  7. Leave Skip the Inbox off during the first test period.
  8. Choose whether to apply the rule to existing matching conversations.
  9. Click Create filter.

Google maintains the current steps in Gmail Help.

Filter examples worth copying

Category Criteria Receipts from one service from:receipts@example.com PDF invoices subject:invoice has:attachment filename:pdf A newsletter list:newsletter.example.com Mail sent to a project alias to:atlas@yourdomain.com Notifications except one sender subject:notification -from:person@example.com

Search operators can be combined. Test the exact query in Gmail before turning it into a rule. Our Gmail filters guide explains grouping, exclusions, and overlap.

Method 2: Use a no-code workflow

A no-code automation service can watch Gmail for a matching message and apply a label or send data to another app. The setup usually follows this pattern:

  1. connect the Gmail account to the automation service
  2. choose a new-message trigger and narrow its search
  3. add an action that applies a Gmail label
  4. test with a real message before turning the workflow on

This method makes sense when labeling is one step in a larger workflow, such as creating a task or recording an attachment. For label-only rules, Gmail’s native filter is simpler and keeps another service out of the mailbox.

Review the service’s Gmail permissions, data retention, error history, and task limits before connecting it.

Method 3: Use an AI label

An exact filter struggles with categories such as “customer question,” “project update,” or “sales pitch.” The sender and wording change, while the intent stays similar.

In Sortie, you define a tag in plain language, connect Gmail, and let the sorter apply the corresponding Gmail label. A useful definition includes both the positive case and an exclusion:

Customer question: a message from a current customer asking for help or a reply.
Exclude receipts, automated alerts, and product announcements.

Start with one or two tags. Check the resulting Gmail labels every day for a week. Only enable automatic archiving for a category after you understand its misses.

Which method should you choose?

Need Gmail filter No-code workflow AI label Exact sender or subject Best fit More setup than needed More setup than needed Send data to another app Limited Best fit Depends on the tool Classify message intent Weak fit Weak without an AI step Best fit Ongoing maintenance Update when formats change Monitor connections and task runs Review category boundaries Risk control Label before archive Test every action Label before archive

Use this quick test:

  • If you can write the rule with from:, to:, subject:, list:, or has:attachment, use a Gmail filter.
  • If a person must read the message to decide, an AI email organizer may fit better.
  • If a wrong result could hide an urgent message, apply a label but do not archive.

You can use both methods in one mailbox. Exact filters can handle receipts and newsletters while AI labels cover changing topics and intent.

Check the result before archiving

Create a temporary label such as Test / Receipts. Let the automation run, then inspect:

  • false positives: mail that received the label incorrectly
  • false negatives: mail that should have received it but did not
  • overlaps: mail that matched more than one automated rule
  • action cost: what would have happened if the message had been archived

Rename the label after the rule proves useful. Delete the rule if the label does not change how you work.

If a Gmail label is not applying

Check that the filter still exists under Settings > See all settings > Filters and Blocked Addresses. Run its criteria as a fresh Gmail search. A changed sender address, mailing-list header, or subject format may explain the miss.

For AI labels, make the category more specific and add exclusions. Avoid categories that combine unrelated actions, such as “important work and interesting reading.” Split those into separate tags.

For the full system, including sorting and archive choices, use the Gmail automation guide.