Contents
The Short Answer
"A Chat Model sub-node must be connected" means the AI Agent node tried to run and found no usable language model on its Chat Model connector. The n8n AI Agent documentation describes it in one line: this error displays when n8n tries to execute the node without having a Chat Model connected.
The fix from the docs:
- Open the AI Agent node and select the + Chat Model button at the bottom of the screen. Or, with the node closed, select the Chat Model + connector underneath it.
- n8n opens a list of possible chat models. Pick the one for your provider.
- Select or create the credential for that provider, and choose a model.
- Run the workflow again.
If a model node is already sitting under the agent and you still get the error, it is either deactivated or not actually wired to this agent. Those are Causes 2 and 3 below.
Why the Agent Needs a Sub-Node at All
Most n8n nodes are self-contained. The AI Agent node is not. It is what n8n calls a root node in a cluster: a main node that defines the job, plus one or more sub-nodes attached underneath that supply the parts. The n8n docs describe the AI Agent this way: connect a chat model and one or more tools, and the agent decides which tools to call to complete a task.
So the agent node holds the instructions and the loop, and the sub-nodes hold everything else:
| Connector | What attaches there | Needed? |
|---|---|---|
| Chat Model | A chat model sub-node, such as OpenAI Chat Model or Anthropic Chat Model, with its credential | Yes. This error is the check for it |
| Memory | A memory sub-node, such as Simple Memory, so the agent remembers earlier turns | Optional |
| Tool | Tool sub-nodes the agent can call | The docs say you must connect at least one tool sub-node |
The check is generic. In the n8n source, get-input-connection-data.ts, any root node input marked as required goes through the same validation, and the message is built from the input's display name. For the agent's model input, that produces:
A Chat Model sub-node must be connected and enabled
The documentation and older versions show the shorter form without "and enabled". It is the same check. The comment in the source states the rule in plain terms: for required inputs, at least one enabled connected node is needed. Other root nodes with required sub-nodes produce the same sentence with a different name at the front.
If you are new to how agents, models and tool calling fit together, our n8n AI Agent tutorial walks through a complete build, and the glossary entry on AI agents covers the concept.
Cause 1: No Chat Model Is Attached
The straightforward case. You added an AI Agent node, wrote a prompt, and ran it. A new AI Agent node arrives with empty connectors, and the model is not chosen inside the node's parameters. It is a separate node.
How to confirm it: look underneath the AI Agent node on the canvas. If the Chat Model connector shows a plus sign and no line leading to another node, nothing is attached.
The fix: follow the steps in the short answer. A few practical notes on choosing:
- Pick a chat model node, and one that supports tools. The n8n docs list the chat models the Tools Agent supports: OpenAI Chat Model, Groq Chat Model, Mistral Cloud Chat Model, Anthropic Chat Model, and Microsoft Foundry Chat Model. Since n8n 1.82.0 every AI Agent node works as a Tools Agent, so that list is the safe starting point.
- The credential lives on the model node. You add the provider's API key there, not on the agent.
- With two agents, consider a model node each. It keeps the wiring obvious and lets you use a cheaper model for the simpler agent.
If you are unsure which model to use, start with a small, inexpensive one from a provider you already have an account with, get the workflow running, and change it later. Swapping the model sub-node does not affect the rest of the agent. Our guide to reducing AI agent LLM costs covers how to choose once it works.
Cause 2: The Model Node Is Attached but Deactivated
This is the case that the "and enabled" in the current message is there for. A deactivated node stays on the canvas and stays wired up, but n8n skips it. For an ordinary node in a chain that is useful. For a required sub-node, it leaves the agent with no model, and the check fails exactly as if nothing were attached.
It usually happens by accident. Deactivate is a single action on a selected node, and it is easy to trigger on the wrong one. It also happens on purpose: someone deactivates the model to stop the workflow spending money during testing and forgets to turn it back on.
How to confirm it: the model node is visibly connected to the agent's Chat Model connector, and the node's menu offers Activate as the available action, where an active node would offer Deactivate.
The fix: select the model node and choose Activate. Run the workflow again.
Check the agent's other sub-nodes while you are there, in case more than one was deactivated at the same time.
Cause 3: The Agent Was Copied Without Its Model
Sub-nodes are separate nodes. When you copy an AI Agent node, by duplicating it or by pasting it into another workflow, you get what you selected. If you selected only the agent, the copy arrives with its prompt and settings intact and nothing on its connectors. Because the settings look complete, it is natural to assume the model came with it.
The same thing happens in a workflow with several agents when a model node is wired to a different agent from the one you think. Sub-nodes sit below their root node, and on a busy canvas two agents side by side can make it hard to see which model belongs to which.
How to confirm it: follow the line from the failing agent's Chat Model connector. The error message is raised on the agent that lacks a model, so start from the node the execution stopped on, not from the model node.
The fix:
- When copying an agent, select the agent and all of its sub-nodes together before you copy, so the cluster moves as one.
- If the copy is already made, add a model to it using the steps in the short answer.
- If the model is on the wrong agent, add a second model sub-node for the agent that needs one.
Workflow templates can leave you in the same position for a different reason: the model node is present, but it needs your own credential before it will do anything. If your error names the model node instead of the agent, look at its credential first.
The Errors You May See Next
Attaching a model gets the agent past its first check. If something else is wrong with the setup, one of these tends to follow. The first is from the n8n source and the rest are from the AI Agent common issues page.
| Message | What it means | Fix |
|---|---|---|
| Tools Agent requires Chat Model which supports Tools calling | A model is connected, but it is not a chat model that can call tools. | Use a chat model node from the supported list, and a model from that provider that supports tool calling. |
| No prompt specified | The agent expects the prompt to come automatically from a Chat Trigger node and it did not. | Change the agent's Prompt parameter from Connected Chat Trigger Node to Define below and build the prompt yourself. |
| Internal error: 400 Invalid value for 'content': expected a string, got null | The Prompt input resolved to null. | Make sure the expression in Text refers to a field that exists, or remove null values from chatInput. |
| Error in sub-node Simple Memory | Often an older version of the memory node, from a copied template. | Remove the Simple Memory node and add it again to get the latest version. |
| The service is receiving too many requests from you | The model provider returned a 429. | See our guide to that error. |
One behaviour of sub-nodes is worth knowing before you put expressions in a model node. The n8n docs explain that sub-nodes resolve expressions differently from other nodes: given several input items, an expression such as {{ $json.name }} in a sub-node always resolves to the first item, not to each item in turn. If you set a model name or an option from incoming data, it will use the first item's value for the whole run.
How to Stop It Coming Back
Treat the agent and its sub-nodes as one unit. Select them together when you copy, move or delete. Keep each agent's sub-nodes directly beneath it so the wiring is obvious.
Rename model nodes to say what they are for. "OpenAI Chat Model" and "OpenAI Chat Model1" tell you nothing. "Model - triage agent" tells the next person which agent breaks if they touch it.
Do not deactivate a model to pause a workflow. Unpublish the workflow instead. Deactivating a required sub-node turns a paused workflow into a broken one.
Run the agent once after any structural change. This error is caught on the first execution. A single test run after copying or rewiring is all it takes to find it before your users do.
Set an error workflow. In Workflow Settings, choose a workflow that starts with the Error Trigger node, so a failed agent run sends you a message. See error handling.
Getting the model attached is step one of a working agent. Choosing tools, writing the system prompt, adding memory and handling failures are where the real work is, and they are what the n8n AI Agents course covers from start to finish. For ready-made starting points, see our n8n AI agent templates, and for how n8n compares as an agent platform, the n8n review.
Sources
Checked against n8n's documentation and source code on 17 November 2026.
- n8n docs: AI Agent common issues - this error and its fix, plus No prompt specified, the Simple Memory error and the 400 content error.
- n8n docs: AI Agent node - what the node needs, and the Tools Agent change from n8n 1.82.0.
- n8n docs: Tools Agent - the supported chat models.
- n8n docs: OpenAI Chat Model common issues - how sub-nodes resolve expressions.
- n8n source: get-input-connection-data.ts - the required input check and the current message wording.
FAQ
- What does "A Chat Model sub-node must be connected" mean in n8n?
- The AI Agent node was executed without a usable language model attached to its Chat Model connector. The agent node does not contain a model. It needs a separate chat model sub-node, such as OpenAI Chat Model or Anthropic Chat Model, connected underneath it.
- How do I connect a chat model to the n8n AI Agent node?
- Open the AI Agent node and select the + Chat Model button at the bottom of the screen, or select the Chat Model + connector on the closed node. n8n shows a list of chat models. Choose one, add the provider credential on that model node, and pick a model.
- A chat model is connected and I still get the error. Why?
- Check whether the model node is deactivated. Current n8n words the error as A Chat Model sub-node must be connected and enabled, and a deactivated sub-node fails the check. Select the model node and choose Activate. Also confirm the model is wired to the agent that failed, not to a different agent.
- Which chat models work with the n8n AI Agent node?
- The n8n docs list OpenAI Chat Model, Groq Chat Model, Mistral Cloud Chat Model, Anthropic Chat Model and Microsoft Foundry Chat Model as supported by the Tools Agent, which is how every AI Agent node works since n8n 1.82.0. The model must support tool calling.
- What does "Tools Agent requires Chat Model which supports Tools calling" mean?
- A model is connected, so the first check passed, but it is not a chat model that can call tools. Replace it with a chat model sub-node from the supported list and choose a model from that provider that supports tool calling.
If this resonated
Module 02 is the long version of this post.
Eval set, refusal pattern, kill switch. Build it in a weekend.
