How to sort Gmail into folders automatically

To sort Gmail into folders automatically, turn on Gmail's inbox categories so new mail goes into the Promotions, Social, Updates and Forums tabs, then add one filter per label for the mail you want out of the inbox. Inbox Hero does it without rules: it files newsletters, promotions and notifications into their own folders as each email arrives, and keeps mail from people in your inbox.

Try free for 7 days

Then 27¢ a day. No card needed.

In Gmail, folders are labels. Categories sort mail into tabs that stay inside your inbox; filters sort mail into labels and can take it out of the inbox. Most people need both, and three or four filters cover the bulk of their mail.

Three ways to sort Gmail automatically

Gmail categoriesGmail filtersInbox Hero
SetupTick boxes in SettingsOne search and one filter per label, on a computerConnect your mailbox; nothing to install
Where mail goesTabs inside the inboxLabels, out of the inbox if you tick Skip the InboxInboxHero folders (labels in Gmail)
A sender you have never seenSorted by GmailSorted only if it matches a ruleFiled as it arrives
A mistakeDrag the email to another tab; Gmail offers to do the same for that senderEdit the filter by handMove it back to your inbox once and it learns
PriceFreeFree27¢ a day: $99 a year, after 7 days free

Step 1: Turn on inbox categories

  1. In Gmail on a computer, click the gear icon, then See all settings.
  2. Open the Inbox tab.
  3. Set Inbox type to Default.
  4. Under Categories, tick the tabs you want: Promotions, Social, Updates, Forums.
  5. Click Save Changes.

Gmail now sorts each new email into a tab. Anything it cannot place stays in Primary. The tabs need no rules, but the mail in them still counts as inbox mail.

Step 2: Create a label for each folder

In the left menu, click the plus icon next to Labels, type a name such as "Shopping" or "Receipts", and click Create. Our guide on how to create folders in Gmail covers nesting labels and creating them on a phone.

Step 3: Add one filter per folder

Pick a search for each folder. Some that work well:

FolderSearch
Shoppingcategory:promotions
Socialcategory:social
Newslettersunsubscribe -category:promotions
Receiptssubject:(receipt OR invoice OR "your order")
Workfrom:(@yourcompany.com)
  1. Type the search into the Gmail search box.
  2. Click the search options icon at the right of the search box, check the results, then click Create filter.
  3. Tick Apply the label and choose the folder's label.
  4. Tick Skip the Inbox (Archive it) if you want this mail out of your inbox.
  5. Tick Also apply filter to matching conversations to sort the mail you already have.
  6. Click Create filter, then repeat for the next folder.

When two filters match one email, Gmail applies both, so the email gets both labels. Not sure of a search? Our free Gmail filter and search builder, no sign-in writes it for you. Filters can only be created in Gmail on a computer, but they then work in the Gmail app on your phone too.

What Gmail's own sorting does well, and where it stops

Categories are free and need no upkeep. Filters are free, exact and run on Google's side, so they work even when your computer is off. For a handful of stable senders, that is all you need.

Filters only match the words and senders you give them. A store you ordered from yesterday or a newsletter you just joined lands in the inbox until you write a rule for it, and a broad search such as unsubscribe also catches mail you wanted to keep in view. A filter never learns from the emails you move back.

The automatic option

If you'd rather not build filters by hand, you can set up automatic email sorting with Inbox Hero. It is an email sorting service that files newsletters, promotions and notifications into folders as they arrive, inside the email app you already use. In Gmail the folders are labels: InboxHero/Newsletters, InboxHero/Shopping, InboxHero/Notifications and InboxHero/Later. Mail from people stays in your inbox, and older mail is filed too, in the background. It also checks every new email for scams and moves suspicious mail to a Fraud folder.

It works with Gmail and Google Workspace accounts, plus Yahoo, AOL, iCloud and other IMAP mailboxes. Nothing is ever deleted on its own, and if an email lands in the wrong place, move it back to your inbox once and Inbox Hero learns. Since September it has filed more than 1.3 million emails for its members. It costs 27¢ a day: $99 a year, after 7 days free.

Frequently asked questions

How do I sort Gmail into folders automatically?

Gmail sorts mail itself in two ways. Turn on inbox categories in Settings, See all settings, Inbox, so new mail goes into the Promotions, Social, Updates and Forums tabs. Then create a label for each folder you want and add one filter per label with Apply the label and Skip the Inbox. To sort without writing rules, Inbox Hero files newsletters, promotions and notifications into their own folders as each email arrives.

Does Gmail have folders?

Gmail uses labels, which work like folders. A filter can put a label on new mail and take it out of the inbox, so the label behaves like a folder the mail was sorted into.

Can a Gmail filter sort the emails I already have?

Yes. When you create the filter, tick Also apply filter to matching conversations and Gmail labels the matching mail you already have as well as new mail.

What happens when two Gmail filters match the same email?

Gmail applies both, so the email gets both labels. If both filters also skip the inbox, it shows under each label. Make your searches narrow if you want one folder per email.

Does Inbox Hero work in the Gmail app?

Yes. There is nothing to install. Inbox Hero works on your mailbox itself, so its folders show as labels in Gmail on your phone and your computer. On a company Google account, your admin may need to allow the app first.

Take back your inbox today

Connect Gmail or any mailbox in one click. Inbox Hero files the noise, drafts your replies, and quarantines phishing. Try it free for 7 days: no card needed, cancel any time.

Try free for 7 days

Updated .Menu names as Gmail shows them in 2026.

Security and privacy

Reviewed by Google. Tested by an independent lab.

Before you connect Gmail, here is what keeps your inbox safe with us, in plain words.

Portrait of Mike Jones

Trusted by Mike Jones and Science Inc., the team behind Dollar Shave Club

“I built Inbox Hero for my own inbox and use it every day. I’d never ask you to trust it with yours if I didn’t.”

Mike Jones
Founder and CEO, Science Inc. Former CEO, Myspace.

Track record

  • Science Inc.Founder and CEO
  • Dollar Shave ClubBuilt at Science
  • Liquid DeathEarly investor
  • MyspaceFormer CEO

Science is the Los Angeles studio and venture firm behind Dollar Shave Club and an early investor in Liquid Death.

Available on the App Store for iPhone Read our privacy policy