- Home
- Resources
- Integrations
- AI Transform
n8n AI Transform nodeConfigure AI Transform in n8n.
The AI Transform node writes the code so you do not have to. Describe the change you want in plain English, click Generate code, and the n8n AI Transform node fills a JavaScript snippet that runs on every item reaching it. Two parameters, nothing to authenticate.
Verified Trustpilot reviews · AI, automation & growth agency
What does the n8n AI Transform node do?
AI Transform takes a prompt written in plain English and turns it into a JavaScript snippet that reshapes the data passing through your workflow. The AI is context-aware: it reads the workflow's nodes and the data types they output, so the code it writes already knows the shape of your items. The node does not start a workflow, it sits after a trigger and runs on each incoming item.
First scenario, tidying contact data before it is stored. A form or an import gives you firstname and lastname in separate fields, and the sheet you feed expects one column. The placeholder in the node says it plainly: merge firstname and lastname into a field details.name and sort by email. Generate the code once, and every run of your Google Sheets append gets the same clean payload.
Second scenario, flattening an API response. A call made with HTTP Request comes back with values buried two levels down. Instructions use dot notation to reach them, the way the node's own description asks: refer to a nested field as address.street. The generated snippet pulls those values up to the top level, and the nodes after it can read them with a plain expression such as {{ $json.street }}, the n8n syntax for reusing a field from the item at hand.
Third scenario, preparing a message body. Before an Gmail send, you want the subject built from two fields and the empty ones dropped. Writing that by hand is five minutes of fiddling with string concatenation. Describing it is one sentence, and the result is readable code you can inspect before the workflow goes live.
When to prefer the alternative. The Code node is the better choice as soon as you want to keep editing the logic: the snippet AI Transform produces is read-only inside the node, and the only ways forward are rewriting the prompt or copying the code into a Code node. Loops you tune by hand, helper functions, anything you expect to revisit in three months, start there.
The limits are worth knowing before you build on it. The prompt stays in plain English and under 500 characters, which rules out a full specification and rewards one clear instruction at a time. The node is at version 1, with those two parameters and nothing else to set. And it runs downstream only: a Schedule Trigger, a Webhook or the trigger of a tool has to open the workflow first.
Which parameters does AI Transform expose?
The AI Transform node has 2 parameters. For each one: the node as you configure it in n8n, what the parameter changes, and our field notes.
Parameters index
Instructions
instructionsWhat you see in n8n
Notes & use cases
This is where the whole node happens. You type what the data should look like, click the Generate code button, and n8n populates the Transformation Code below with a JavaScript snippet built for the items your workflow carries.
Key parameters
- Instructions: the prompt itself, written in plain English and kept under 500 characters; use dot notation to point at a nested field, for example
address.street.
details.name and sorting the result by email, the example n8n suggests in the field placeholder. Anything you can state in one sentence about the shape of an item belongs here.Generated JavaScript
jsCodeWhat you see in n8n
Notes & use cases
Below the prompt sits the snippet the node produced. Reading it is the point: it shows exactly what will run against each item, so nothing is hidden behind the prompt you typed.
Key parameters
- Generated JavaScript: read-only inside AI Transform; to change what it does, adjust the instructions, or copy and paste the code into a Code node and keep going from there.
Need help automating AI Transform with n8n?
A person reads every message.
AI Transform in n8n, common questions
01Is the AI Transform node included in n8n?
02What do you need to set up before using it?
03What are the limits of the n8n AI Transform node?
04AI Transform or the Code node?
05n8n or Make for this kind of data reshaping?
Get our weekly integration tips.
No spam. Unsubscribe anytime.



