# What is an AI agent?

> An AI agent decides what to do and uses tools to do it, like adding rows to a sheet. A plain definition, a real n8n build, and how to keep it safe.

Source: https://learn.ynteractive.com/content/glossary/ai-agent · Updated 2026-10-01 · Free from Stepthrough (https://learn.ynteractive.com)

[AI agents](https://learn.ynteractive.com/content/glossary#topic-ai-agents) · [AI glossary](https://learn.ynteractive.com/content/glossary)

Updated October 1, 2026 · By [Robert Breen](https://learn.ynteractive.com/content/about)

An AI agent is an AI system that works toward a goal by deciding which steps to take and using connected tools to take them, such as adding a row to a spreadsheet or creating an email draft, rather than only replying with text. You set the goal, the tools and the limits.

## Why it matters for a small business

Agents earn their keep where the input varies and the right action depends on reading it: a batch of expenses to categorize, a list of late purchase orders to chase, a receipt photo to log. The agent reads, decides and writes the result where your team will see it, with no copy and paste in between.

Because an agent acts, its mistakes travel further. A bad chatbot answer is a bad paragraph; a bad agent action is a wrong row in the books or a message to a customer. Good agents get narrow jobs, only the tools they need, and permissions that keep a person in the loop, like creating drafts instead of sending.

## In a real lesson: n8n AI Agent Tutorial: Save Social Media Ideas to Google Sheets

The [n8n AI agent lesson](https://learn.ynteractive.com/content/n8n-ai-agent-tutorial-google-sheets) assembles one piece by piece for BrightPath Marketing, a made-up marketing agency. The **AI Agent** node is introduced as the piece that can plan and then carry out actions with the tools you give it. It gets a **System Message** naming the agency, its audience and voice, and the five things to return for each idea: Platform, Post Topic, Hook, Short Description and Suggested Call to Action. Then come an **OpenAI Chat Model** set to **gpt-5-mini**, **Simple Memory**, and a **Google Sheets Tool** pointed at a sheet called **Social Media Ideas**.

In the test you ask for 3 post ideas about how small businesses can use ChatGPT to improve their advertising, and it replies with three. Then you send **Yes, save those ideas to the sheet**. Nobody tells it which node to run; the agent works out that saving means the Sheets tool and writes one row per idea.

That choice is what makes it an agent. The system message says when to use the tool, memory tells it which ideas "those" means, and the tool does the writing.

[Try this lesson free](https://learn.ynteractive.com/modules/n8n-ai-agent) or [read the step-by-step guide](https://learn.ynteractive.com/content/n8n-ai-agent-tutorial-google-sheets).

## Common confusions

### AI agent vs automation

A plain [automation](https://learn.ynteractive.com/content/glossary/automation) runs the same fixed steps every time. An agent chooses its steps based on what it reads, within the tools you give it. Many useful workflows combine both.

### AI agent vs chatbot

A [chatbot](https://learn.ynteractive.com/content/glossary/chatbot) replies. An agent can also act through tools, and decides when to.

### "Autonomous" vs supervised

Most useful small-business agents aren't left fully on their own. In the [email responder lesson](https://learn.ynteractive.com/content/ai-email-responder-gmail-drafts-n8n), the agent's only tool creates Gmail drafts, so a person still reads and sends every reply.

## Tips

- Start with one job and one tool, then add more once it works.
- Say in the system message exactly when each tool should be used.
- Prefer safe actions (append a row, create a draft) over ones you can't undo (send, delete).

## Related terms

[AI Agent node](https://learn.ynteractive.com/content/glossary/ai-agent-node) · [Tool calling](https://learn.ynteractive.com/content/glossary/tool-calling) · [Agent memory](https://learn.ynteractive.com/content/glossary/agent-memory) · [Chatbot](https://learn.ynteractive.com/content/glossary/chatbot) · [Human in the loop](https://learn.ynteractive.com/content/glossary/human-in-the-loop) · [System prompt (system message)](https://learn.ynteractive.com/content/glossary/system-prompt)

## Where you use it: free lessons

- [n8n AI Agent Tutorial: Save Social Media Ideas to Google Sheets](https://learn.ynteractive.com/content/n8n-ai-agent-tutorial-google-sheets) (n8n, 12 min)
- [AI Email Responder: Draft Gmail Replies Automatically with n8n](https://learn.ynteractive.com/content/ai-email-responder-gmail-drafts-n8n) (n8n, 12 min)
- [AI Receipt Extractor: Receipts to Google Sheets with n8n](https://learn.ynteractive.com/content/ai-receipt-extractor-n8n-google-sheets) (n8n, 12 min)

## More free tutorials

[n8n Jump Start](https://learn.ynteractive.com/content/path/n8n-jump-start)

## Prompt templates that use it

[Service call follow-up message prompt](https://learn.ynteractive.com/content/prompts/service-call-follow-up-message-prompt)

## Visual guides

AI agent in a few slides, with the same guide written out as text.

- [5 Steps to an AI Agent That Categorizes Business Expenses](https://learn.ynteractive.com/content/visual/5-steps-ai-expense-categorizer): A visual guide: an n8n agent sorts expenses into a fixed list of categories, flags unclear ones as Needs Review and saves them to Google Sheets.
- [5 Steps to an n8n AI Agent That Saves to Google Sheets](https://learn.ynteractive.com/content/visual/5-steps-n8n-ai-agent-google-sheets): A visual guide: build an n8n AI agent that writes social media ideas and saves each one as a Google Sheets row, in 5 steps from the free lesson.
- [What Is an AI Agent? A Visual Guide](https://learn.ynteractive.com/content/visual/term-ai-agent-explained): A visual guide to AI agents: AI that decides which steps to take and uses tools to take them, shown in a real n8n lesson, with tips to keep it safe.

[All visual guides](https://learn.ynteractive.com/content/visual)

## Frequently asked questions

**Do I need to code to build an AI agent?**

No. In n8n you connect nodes on a canvas: a trigger, the AI Agent, a chat model, memory and tools. The instructions are written in plain English.

**What is the difference between an AI agent and a Custom GPT?**

A Custom GPT is a configured chat assistant that someone opens and types into. An n8n agent can be started by a chat, a form or an email, and it can write to your tools.

[All AI glossary terms, A to Z](https://learn.ynteractive.com/content/glossary) · [Free prompt templates](https://learn.ynteractive.com/content/prompts)
