PICKED FROM N8N.IO · EMAIL & INBOX
Fetches unflagged, uncategorised emails from Outlook, strips the HTML and passes each one to an AI agent running on Ollama. The model assigns a category such as Action, Junk, Business or SaaS. The workflow applies the category in Outlook and moves messages like junk or receipts to the matching folders.
Template by Wayne Simpson · 74.2k views on n8n.io · listed there as “Auto categorise Outlook emails with AI”
- DIFFICULTY
- Advanced
- NODES
- 26
- USES AI
- Yes
- PUBLISHED
- October 2024
001 / WHAT HAPPENS
- 01
Emails are fetched from Outlook, skipping flagged ones and those already categorised.
- 02
Each email is converted to plain Markdown to remove HTML clutter.
- 03
An AI agent using an Ollama model picks a category and returns it as JSON.
- 04
A Switch step matches the category to the right Outlook action.
- 05
The email is categorised and moved to folders such as Junk Email or Receipts.
WHO IT SUITS
Suits busy owners or admin staff on Microsoft 365 who want their inbox sorted, and who can run or replace a local Ollama model.
CONNECTS
- Microsoft Outlook
- Ollama
002 / BEFORE YOU USE IT HERE
- !It uses an Ollama model, which needs a self-hosted server you run yourself; email content stays on that server, though swapping to a hosted AI model sends it overseas under APP 8.
- !It moves emails to Junk automatically, so check categories on a small batch first in case real customer emails are misfiled.
- !Category names appear in several nodes and must match exactly; customise them for your business.
LOCAL SWAP
Swap the Ollama chat model for an OpenAI chat model if you do not self-host.
Need n8n and the AI hosted in Australia? →003 / MORE FOR EMAIL & INBOX
- 8 NODESAI
EMAIL & INBOX
Draft Gmail replies to customer emails with OpenAI
GmailOpenAIBeginnerby Nicolas Chourrout76.4k views - 10 NODESAI
EMAIL & INBOX
Draft AI email replies and approve them by email before sending
IMAP emailOpenAIBeginnerby Davide Boizza40.5k views - 11 NODESAI
EMAIL & INBOX
Auto-label incoming Gmail messages with AI
GmailOpenAIBeginnerby Oskar30.7k views
004 / QUESTIONS
Anything else is quicker to answer on a call. Thirty minutes, free, with the people who would build it.
Yes. Every template on this list is free on n8n.io. You need an n8n account (n8n Cloud or self-hosted) and accounts for the apps it connects to, some of which charge for API use.
We adapt templates to your systems, add approval steps where customers are involved, host n8n in Australia when the data calls for it and hand it over documented.
Book a free call→