- Home
- Resources
- Integrations
- Text Classifier
n8n Text Classifier nodeConfigure Text Classifier in n8n.
The n8n Text Classifier node reads a piece of text and files it under one of the categories you wrote yourself. Seven parameters shape how it decides, and one port feeds it a chat model. Handy the moment a workflow has to branch on what a message means.
Verified Trustpilot reviews · AI, automation & growth agency
What does the n8n Text Classifier node do in a workflow?
It takes each item that reaches it, hands the text to a language model, and decides which of your categories fits. The categories are not a fixed list shipped by n8n: you write them, with a name and an optional description, and the node builds one output branch per category. An item that lands in the support category leaves through the support branch, and the rest of the workflow can stay simple.
Think of it as an if statement that reads. A router in n8n compares values it can test, so it needs a field that already holds the answer. The classifier works on plain language, which is what arrives when a human writes to you.
Three shapes come back often. Inbound mail: a message pulled by Gmail goes through the classifier with categories like billing, bug and sales, and each branch ends in a different place. Support triage: a ticket body gets a category, the branch posts it in the matching Slack channel, and nobody re-reads the queue by hand. Chat input: a message from a chat trigger is classified before anything else runs, so a question about pricing never reaches the same branch as a bug report.
The node needs a model to think with. You connect one sub-node on its Chat Model port, for example an OpenAI Chat Model or an Anthropic Chat Model, and that sub-node carries the credential, the stored account details n8n reuses across workflows. The classifier itself has nothing to authenticate.
When the category is not the end of the job, look elsewhere. The classifier gives you a branch and stops there. If the workflow has to answer, look things up or call other nodes as tools, the AI Agent node is the root node for that, and the classifier often sits in front of it to decide which agent runs at all.
Known limits, so you are not surprised. Categories exist only in the node: nothing is stored, nothing is learned between runs, and two workflows that classify the same way need the same list twice. An item that matches nothing is dropped unless you turn on the Other branch. And the model provider bills its own API calls under its own terms, whatever n8n does.
What do you plug into it?
This node is a root node: it receives the workflow items through its main input, and sub-nodes, the small blocks that never run on their own, attach to the ports drawn under it.
Ports (what plugs in)
- Chat Model
ai_languageModelrequired
01Chat Model
The port that supplies the model doing the reading. Drag a chat model sub-node onto it and the classifier sends each text plus your category list to that model. Leave it empty and the node cannot run at all.
Key parameters
- Required: the classification happens inside the model, so an empty port blocks the execution.
- OpenAI Chat Model or Anthropic Chat Model: the usual starting points, each holding its own provider credential.
- Ollama Chat Model: the choice when the text should stay on your own machine.
- Google Gemini Chat Model: another hosted option if the account already exists.
How do you configure each parameter?
The Text Classifier node has 7 parameters. For each one: the node as you configure it in n8n, what the parameter changes, and our field notes.
Parameters index
Text to Classify
inputTextWhat you see in n8n
Notes & use cases
This is the text the model reads. Everything else in the node describes how to judge it, this field says what gets judged.
Key parameters
- Text to Classify: required. Use an expression, the n8n syntax that pulls a value from an earlier node, to reference data in previous nodes, or type static text. By default it references the
textfield.
{{ $json.chatInput }} so the visitor's own sentence is what gets sorted, not a label someone typed upstream.Categories
categoriesWhat you see in n8n
Notes & use cases
Here you write the buckets. Each entry added with Add Category becomes one output branch on the node, in the order you listed them.
Key parameters
- Category: required, the name of the category to add. It is also the label printed on the branch.
- Description: describe your category if it is not obvious, so the model knows what you mean by it.
billing saying it covers invoices and refunds keeps payment questions out of the sales branch.Allow Multiple Classes To Be True
options.multiClassWhat you see in n8n
Notes & use cases
Some texts genuinely belong in two places. This switch decides whether the node is allowed to say so.
Key parameters
- Allow Multiple Classes To Be True: turned off, the node outputs a single class per item. Turned on, the model can select several, and the item leaves through every branch it matched.
When No Clear Match
options.fallbackWhat you see in n8n
Notes & use cases
Not every item fits. This option defines what happens to the ones that match nothing well enough.
Key parameters
- Discard Item (
discard): the default. The item is ignored and dropped from the output, silently. - Output on Extra, 'Other' Branch (
other): creates a separate output branch called Other, where unmatched items leave.
System Prompt Template
options.systemPromptTemplateWhat you see in n8n
Notes & use cases
The node already sends the model a set of instructions. This option replaces that text with a string you write yourself.
Key parameters
- System Prompt Template: a string used directly as the system prompt template. It uses the
{categories}placeholder, which is where your category list gets injected.
{categories} placeholder from your string and the model never sees the list.Enable Auto-Fixing
options.enableAutoFixingWhat you see in n8n
Notes & use cases
A model sometimes answers in a shape the node cannot parse. Auto-fixing gives it a second chance instead of failing the run.
Key parameters
- Enable Auto-Fixing: when enabled, the node sends the schema parsing error back to the model and asks it to fix the output so it matches the expected format. It may trigger an additional model call.
Batch Processing
options.batchingWhat you see in n8n
Notes & use cases
When hundreds of items arrive at once, the pace matters more than the speed. This collection controls it.
Key parameters
- Batch Size: how many items to process in parallel. Useful for rate limiting, but it might affect the ordering of the log output.
- Delay Between Batches: a delay in milliseconds between batches, again for rate limiting.
Need help automating Text Classifier with n8n?
A person reads every message.
Questions people ask next
01Is the Text Classifier node included in n8n?
02What do you need to make the n8n Text Classifier node work?
03What are the limits of the Text Classifier node?
04What is the minimum you should connect to start?
05n8n or Make for classifying text?
Get our weekly integration tips.
No spam. Unsubscribe anytime.

