You built a workflow in n8n, it works, and now everyone online is talking about “agents”. You drop the AI Agent node on the canvas, connect it, ask it something simple, and it either does nothing useful or calls the wrong tool three times. Frustrating. And very normal for a first agent.
The short answer: an n8n AI agent workflow is a trigger, one AI Agent node, a chat model, a memory, and a small set of tools the agent may choose from. The model decides which tool to call, n8n runs it, and the agent answers with the result. Keep the first one to three tools, write a clear system message, and put human approval on any tool that sends or changes something. Below you build exactly that: a meeting-prep agent that reads your calendar and email, then drafts a short prep note for you to check.
No password needed – your reset opens instantly.
No password. Just your email, and you’re in.
Short, practical AI lessons for your work week. Join Launchpad free, right above.
What an n8n AI agent workflow actually is
A normal n8n workflow is a fixed recipe. Step 1, then step 2, then step 3, every time. If you followed our n8n tutorial for beginners, you built one of those, with a single AI step in the middle that rewrites some text.
An agent is different. You give it a goal and a toolbox, and it picks the steps itself. n8n describes the AI Agent node like this: connect a chat model and one or more tools, and the agent decides which tools to call to complete a task (n8n docs: AI Agent).
That freedom is the whole point, and also the whole risk. A fixed recipe can’t surprise you. An agent can. So the craft of a good n8n agent is mostly about limits: few tools, clear instructions, and a person approving anything that leaves your account.
Not sure you need an agent at all? Our guide on how to build an AI agent without code helps you decide, and covers the same idea in Zapier and Make.
The five parts of every n8n AI agent
Open any working agent workflow in n8n and you will find the same five parts. Learn these and you can read almost any agent template.
- Trigger: what starts the run. For a chat agent that is the Chat Trigger. It can also be a schedule, a form, or a new email.
- AI Agent node: the “brain” box in the middle. Since n8n 1.82.0 every AI Agent node works as a Tools Agent, so there is no agent type to pick anymore (n8n docs).
- Chat model: the language model that does the thinking, for example the OpenAI or Anthropic chat model sub-node.
- Memory: lets the agent remember earlier messages in the same conversation. Simple Memory is the easy starting point.
- Tools: the actions the agent is allowed to take. Gmail, Google Calendar, Google Sheets, Slack, an HTTP Request and many more. n8n requires at least one tool on an AI Agent node.
On the canvas, the model, memory and tools hang underneath the agent as small “sub-nodes”. That is why it looks different from a normal workflow. Nothing to fear, they are just plugged into the agent instead of lined up after it.
Before you build: pick one job
The fastest way to fail is “an agent that handles my inbox”. Too big, too vague, too many tools. Pick one job you do every week that has a clear finish line.
Our example: meeting prep. Before a client call you open your calendar, search your email for the last messages with that person, and jot down what’s open. Ten minutes, every meeting. The agent does the looking up and writes the note. You read it and walk into the call prepared.
Why this is a good first agent:
- It mostly reads. Reading your calendar and searching your mail can’t hurt anyone.
- It has one write step (a Gmail draft), and you’ll put approval on it.
- You can check the result in seconds. You know your own meetings.
Build the meeting-prep agent, node by node
You need an n8n account (n8n Cloud has a free trial with no credit card, or the free self-hosted Community Edition), plus a Google account with Gmail and Calendar. Plan on about 45 minutes the first time.
Step 1: Add a Chat Trigger
Start a new workflow and choose On chat message as the trigger. This gives you a chat window right inside the editor, so you can talk to your agent while you build. Leave Make Chat Publicly Available off for now. n8n’s own advice is to keep it off while building and only turn it on when you are ready (n8n docs: Chat Trigger).
Step 2: Add the AI Agent node and a chat model
Click the plus after the trigger and add AI Agent. Leave Prompt on “Take from previous node automatically”, so the agent reads whatever you type in the chat.
Under the agent, click Chat Model and pick one, for example OpenAI Chat Model or Anthropic Chat Model, then add your API key as a credential. n8n’s Cloud plans also list “AI models without API keys” as a feature, so check your plan before you go and create a key (n8n pricing).
Step 3: Add Simple Memory
Click Memory under the agent and add Simple Memory. Its Context Window Length setting decides how many earlier messages the agent keeps in mind. The default is fine to start.
Two honest limits: n8n says this memory doesn’t persist between sessions (n8n docs: Tools Agent), and Simple Memory doesn’t work in an active production workflow when n8n runs in queue mode (n8n docs: Simple Memory). For a personal prep assistant, that’s fine. It only needs to remember the current chat.
Step 4: Give it two read tools
Click Tool under the agent.
- Google Calendar tool, operation Event: Get Many. Pick your calendar. For the time range fields, click the small “let the model define this” button so the agent fills them in from your question.
- Gmail tool, operation Message: Get Many. Set a sensible limit (10 is plenty) and let the model fill in the search filter, so it can look up mail from the person you’re meeting.
That button writes a $fromAI() expression for you. You can also type it yourself, with a hint for the model, like {{ $fromAI('search', 'Gmail search query, for example from:name@company.com', 'string') }}. The key isn’t a reference to existing data. It’s a hint the model uses to fill in the right value (n8n docs: $fromAI()).
Give each tool a clear name on the canvas, like “Read my calendar” and “Search my email”. The agent sees those names and descriptions when it decides what to use.
Step 5: Add a write tool, behind human review
Now the one action that leaves a trace: a Gmail tool with operation Draft: Create. It saves the prep note as a draft in your own mailbox. It doesn’t send anything.
Even so, put it behind approval. In the agent’s Tools panel, find the Human review section, pick a channel (the built-in Chat works, so do Slack, Telegram, Gmail and others), and connect the draft tool to that review step. When the agent wants to use it, the workflow pauses and asks you to approve or deny, showing which tool and which values it wants to use (n8n docs: Human-in-the-loop for tools). n8n lists human approval for tool calls on its Cloud plans, including Starter.
Later, if you ever add a tool that sends mail or changes a record, it goes behind the same review step. That’s the habit worth building on agent number one.
Step 6: Write the system message
Open the AI Agent node, go to Options, add System Message, and paste something like this. Change the names to your own.
You are my meeting-prep assistant. I am a freelance consultant. When I name a meeting or a day: 1. Use "Read my calendar" to find the meeting. If you find more than one match, ask me which one. 2. Use "Search my email" to find the last messages with the attendees. Search by their email address. 3. Write a prep note with: who I'm meeting, what we last discussed, open questions or promises, and 3 questions I could ask. Rules: - Only use facts from my calendar and email. If something isn't there, say "not found". Never guess. - "Save draft" needs my approval. If I deny it, don't try again. Just show the note in the chat. - Keep the note under 200 words.
Notice the line about a denied approval. n8n recommends telling the agent which tools need approval and how to respond when you say no, so it handles it gracefully instead of trying again (n8n docs).
Step 7: Test it in the chat
Click Open chat and try: “Prep my next meeting tomorrow.” Watch the canvas. Each tool lights up as the agent uses it, and you can click into every step to see exactly what it sent and got back.
When it works, save the workflow and publish it. From now on, one chat message gets you a prep note, instead of ten minutes of clicking between tabs.
Test it like a new colleague, not a demo
A demo is one happy question. Real work is messy. Before you trust it, run these five tests:
- A meeting that doesn’t exist. It should say “not found”, not invent one.
- Two meetings with similar names. It should ask which one.
- A new contact with no email history. The note should say so plainly.
- Deny the draft. It should show the note in chat and stop.
- A vague question, like “anything important this week?” See if it stays inside its job.
If something goes wrong, open the AI Agent options and turn on Return Intermediate Steps. You’ll see each tool call the agent made, which makes it much easier to spot where it went off track. The Max Iterations option (10 by default) caps how many rounds the model gets, which stops a confused agent from looping (n8n docs: Tools Agent).
Most fixes are in the system message, not the nodes. Vague answer? Make the instruction more specific. Wrong tool? Rename the tool so its job is obvious.
What an agent workflow costs to run
Two meters run at the same time.
- n8n executions. n8n bills by executions, one full run of a workflow. With a Chat Trigger, every message is an execution, so a chat of 10 messages uses 10 (n8n docs: Chat Trigger). The Cloud trial includes 1,000 executions, and paid Cloud plans start at the Starter plan (n8n pricing). Self-hosting the Community Edition has no execution bill, but you run the server.
- The AI model. If you use your own OpenAI or Anthropic key, every agent step is billed by that provider. One prep note usually means a few model calls (decide, read calendar, search mail, write), not one.
For a personal assistant you use a few times a day, the execution count stays small. It’s a public chatbot on your website that can surprise you, which is one more reason to keep that “public” switch off until you’ve seen the numbers.
When a plain workflow beats an agent
Honest point: plenty of jobs don’t need an agent. If the steps are the same every time, a fixed workflow is cheaper, faster and more predictable.
- Same steps every time? Use a normal workflow with one AI step. Our n8n invoice processing workflow is a good example. Invoices always go Gmail, read PDF, Sheet.
- Need to decide what to look up, or ask a follow-up question? That’s agent work. Meeting prep is like that, because every meeting needs a different search.
A good middle ground: a fixed workflow that runs on a schedule, with an agent inside it for the one step that needs judgment. Our n8n CRM automation guide shows that pattern with an AI summary inside regular workflows.
Four mistakes that break a first n8n agent
- Too many tools. Ten tools on agent number one means the model has ten ways to get it wrong. Start with two or three.
- No system message. Without one, the agent guesses what you want. Write down the job, the steps and the rules.
- Write tools without review. Sending mail, updating a CRM or deleting anything should go behind human review until you trust it fully.
- Testing only the happy path. Run the five tests above. The wrong answers teach you more than the right ones.
Where to go next
Once this agent runs, you can reuse the same skeleton for other jobs by swapping the tools and the system message:
- Qualify incoming leads with a scoring prompt: AI agent for lead qualification.
- Let an agent offer and book time slots: AI agent for appointment booking.
- Answer customer questions with a clear handoff to a person: automate customer support with AI agents.
- Still choosing a builder? Compare n8n with Zapier, Make and others in no code AI agent builder: how to pick.
And if you want one practical lesson like this at a time, start free with Launchpad on the RobotsHelp home page.
FAQ
Do I need to code to build an AI agent workflow in n8n?
No. Everything above is clicking and filling in fields. You will see expressions like $fromAI(), but the button writes them for you. n8n does let you add code steps later if you want.
Which chat model should I use for an n8n agent?
Use one you already pay for or know. The Tools Agent supports, among others, the OpenAI, Anthropic, Groq and Mistral Cloud chat models (n8n docs). Pick a model that is good at tool calling, and test with your real questions.
Why does my agent remember nothing the next day?
Simple Memory only holds the current conversation, and n8n notes that memory doesn’t persist between sessions. If you need longer memory, n8n offers other memory sub-nodes backed by a database, but for meeting prep you rarely need it. The facts live in your calendar and email anyway.
Can the agent send emails by itself?
Only if you give it a send tool. In this build it can only create a draft, and only after you approve. Keep it that way until you’ve seen it work for a few weeks.
Is n8n better than Zapier for AI agents?
Different, not better. n8n gives you more control over each piece and can run on your own server. Zapier is quicker if your apps are already connected there. Our n8n vs Zapier comparison goes deeper.
Build yours this week
Pick one meeting you have coming up. Build the agent, ask it to prep that meeting, and compare its note with what you would have written. If it got 80 percent there, you just bought back ten minutes before every call. If it didn’t, the fix is almost always one clearer line in the system message.
No password needed – your reset opens instantly.
No password. Just your email, and you’re in.
Sources
- n8n docs: AI Agent node
- n8n docs: Tools Agent (system message, max iterations, supported models)
- n8n docs: Human-in-the-loop for tools
- n8n docs: Use AI for parameters ($fromAI)
- n8n docs: Simple Memory
- n8n docs: Chat Trigger
- n8n docs: Gmail node operations
- n8n docs: Google Calendar node operations
- n8n pricing and plans
New to agents in general? Start with our AI agents course guide and a simple 4 week plan.