Updated October 21, 2026 · App names checked against vendor documentation; vendors rename things, so search the step picker for the key word if a name differs.
What AI email sorting does (and doesn't do)
Each new email is read by an AI step that picks one category (for example Lead, Customer, Billing, Vendor, Urgent or FYI) and writes a one-line summary. Your automation then adds a matching Gmail label and, for the important categories, sends you a short alert.
What it doesn't do: delete, archive or reply to anything. You still read your mail. You just open the AI/Lead and AI/Urgent labels first and leave the vendor pitches for Friday.
Try Gmail's built-in tools first
If most of your sorting is predictable (the same senders, the same subjects), plain Gmail filters do it for free: Settings › Filters and blocked addresses › Create a new filter. Gmail's own Promotions and Updates tabs also catch a lot of newsletters. AI earns its place when the category depends on what the email says. A new customer and an existing one can write from addresses you've never seen, and a complaint doesn't come with a subject line that says 'complaint'.
Step 1: Create your labels
In Gmail, create a parent label AI with these nested labels:
- AI/Lead: potential new customers asking about your services.
- AI/Customer: existing customers with a question, change or problem.
- AI/Billing: invoices, receipts, payments, bank and tax.
- AI/Vendor: sales pitches, newsletters, cold outreach, 'SEO services' offers.
- AI/Urgent: same-day deadlines, complaints, legal notices, safety issues.
- AI/FYI: everything else.
Six categories is plenty. More than about eight and the AI (and you) start to blur the lines.
Step 2: The classifier prompt
Classify this email for a small business owner. Reply in exactly this format and nothing else:
CATEGORY | one-line summary (max 15 words)
Categories:
Lead = a potential new customer asking about our services
Customer = an existing customer with a question, change or problem
Billing = invoices, receipts, payments, bank, tax
Vendor = sales pitches, newsletters, cold outreach, SEO/marketing offers
Urgent = a same-day deadline, a complaint, a legal notice, or a safety issue
FYI = everything else
Our business: [one sentence on what you do], so a request for [your main services] is a Lead.
From: {{From}}
Subject: {{Subject}}
Body (first 1500 characters): {{Body Plain}}The fixed output format matters. Because the category always comes before the | character, your automation can split it out reliably and use it to pick the label.
Step 3: Build it in Zapier, Make or n8n
Zapier:
- Trigger: Gmail › New Email Matching Search with a search like in:inbox -from:me -label:AI so you don't re-sort mail you've already handled.
- Action: ChatGPT (OpenAI) › Conversation (or AI by Zapier) with the classifier prompt.
- Action: Formatter by Zapier › Text › Split Text on " | " to separate the category from the summary.
- Action: Gmail › Add Label to Email, choosing the label that matches the category (use Paths, or a Lookup Table in Formatter, to map Lead → AI/Lead and so on).
- Action: Filter by Zapier to continue only for Urgent or Lead, then Slack › Send Direct Message or Twilio › Send SMS to yourself with the summary.
Make: Gmail › Watch emails → OpenAI › Generate a response → Router with one route per category → a Gmail module to add the label on each route, plus a Slack › Create a Message on the Urgent and Lead routes.
n8n: n8n has a purpose-built Text Classifier node. Connect Gmail Trigger → Text Classifier (with an OpenAI chat model attached, and your six categories and descriptions entered) → one output per category → Gmail node (Add Labels) on each branch, with a Slack node on the Urgent and Lead branches. You get the branching without writing the format rules yourself.
{{Category}} from {{From Name}}: {{Summary}}. Open Gmail label AI/{{Category}}.Step 4: Watch it for a week before trusting it
- Turn it on and leave your normal habits unchanged.
- Once a day, skim each AI label for anything in the wrong place.
- When something is misfiled, add a line to the prompt: "Emails from our accountant ([address]) are Billing" or "Booking confirmations from [booking tool] are FYI."
- After a week of clean results, start working from the labels first.
Keep it to labelling only. Don't let the automation archive, delete or mark anything as read. If it gets something wrong, the email is still sitting in your inbox.
Costs and privacy
- Usage adds up with volume. Every email is one AI request plus several automation steps. If you get hundreds of emails a day, check your automation plan's task or operation limits, and consider a Gmail filter that skips obvious newsletters before the AI step.
- Send only the first part of the body. The first 1,500 characters are almost always enough to classify an email, and sending less costs less.
- Think about sensitive mail. If you receive health, legal or financial details, exclude those senders with your search, or self-host n8n so the data stays on your server (the AI provider still sees whatever you send it).
What to do with the labels next
Sorting is the first step. Feed AI/Lead into AI lead follow-up so new inquiries get a fast first reply, and feed AI/Customer into AI email reply drafts that answer common questions from your FAQ. AI/Billing pairs naturally with automatic invoice reminders.
Want this and 11 more automations, step by step?
The Small Business Autopilot pack has 12 automations like this one, each with setup in Zapier, Make and n8n, copy-paste AI prompts, message templates and an honest time-saved estimate.
Get the pack — $19 Free 2-automation sample
Not sure where to start? Try the free automation idea finder: pick your business type and get 5 ideas.