Core Concepts
Relevant source files
The following files were used as context for generating this wiki page:
- packages/nodes-base/nodes/HttpRequest/HttpRequest.node.json
- packages/nodes-base/nodes/Webhook/Webhook.node.json
- packages/nodes-base/nodes/Set/Set.node.json
- packages/nodes-base/nodes/Function/Function.node.json
- packages/nodes-base/nodes/If/If.node.json
- packages/nodes-base/nodes/Github/Github.node.json
- packages/nodes-base/nodes/GraphQL/GraphQL.node.json
- packages/nodes-base/nodes/Mattermost/Mattermost.node.json
- packages/nodes-base/nodes/HtmlExtract/HtmlExtract.node.json
- packages/nodes-base/nodes/Airtable/Airtable.node.json
- packages/nodes-base/nodes/NoOp/NoOp.node.json
- packages/nodes-base/nodes/Slack/Slack.node.json
- packages/nodes-base/nodes/Merge/Merge.node.json
- packages/nodes-base/nodes/MongoDb/MongoDb.node.json
- packages/frontend/editor-ui/src/constants.ts
- packages/nodes-base/nodes/Cron/Cron.node.json
- packages/nodes-base/nodes/Start/Start.node.json
- packages/nodes-base/nodes/Google/Sheet/GoogleSheets.node.json
- packages/nodes-base/nodes/Markdown/Markdown.node.json
- packages/nodes-base/nodes/ReadBinaryFile/ReadBinaryFile.node.json
- packages/nodes-base/nodes/Webflow/Webflow.node.json
- packages/nodes-base/nodes/HtmlExtract/test/workflow.dotNotation.json
- packages/frontend/editor-ui/src/components/WhatsNewModal.test.ts
- packages/nodes-base/nodes/CompareDatasets/CompareDatasets.node.json
- packages/nodes-base/nodes/Xml/Xml.node.json
Nodes are the fundamental building blocks of n8n workflows. Each node represents a specific action, trigger, or logical operation. They can be connected to form a sequence of operations, allowing for the creation of complex automation and data processing pipelines. Nodes can range from simple utility functions, like setting data or branching logic, to complex integrations with third-party services like Slack, Google Sheets, or GitHub.
The system defines a wide variety of nodes, each with its own configuration, purpose, and behavior. They are organized into categories and subcategories to help users find the right tool for their task. This document outlines the core concepts of n8n nodes, their structure, categorization, and key types.
Node Definition
Each node is defined by a .node.json file that contains metadata about its functionality, appearance in the UI, and documentation links.
Structure of *.node.json
The following table describes the key properties found in a node's JSON definition file.
| Property | Description | Example | Source |
|---|---|---|---|
node | A unique identifier for the node type. | n8n-nodes-base.httpRequest | HttpRequest.node.json:2 |
nodeVersion | The version of the node definition. | 1.0 | HttpRequest.node.json:3 |
codexVersion | The version of the codex. | 1.0 | HttpRequest.node.json:4 |
details | A description of the node's functionality, often displayed in the UI. | "The IF node can be used to implement binary conditional logic..." | If.node.json:5 |
categories | An array of categories the node belongs to, used for organization in the UI. | ["Development", "Core Nodes"] | HttpRequest.node.json:5 |
subcategories | An object mapping a parent category to its subcategories. | { "Core Nodes": ["Flow"] } | If.node.json:56 |
resources | An object containing links to primary and credential documentation. | { "primaryDocumentation": [...] } | HttpRequest.node.json:6 |
alias | An array of alternative names or keywords for the node to improve searchability. | ["Router", "Filter", "Condition"] | If.node.json:55 |
Node Identification in Code
Within the n8n frontend and backend, nodes are referenced by unique string constants. These constants ensure consistency and prevent errors from typos.
Sources: packages/frontend/editor-ui/src/constants.ts:160-256
export const HTTP_REQUEST_NODE_TYPE = 'n8n-nodes-base.httpRequest';
export const IF_NODE_TYPE = 'n8n-nodes-base.if';
export const START_NODE_TYPE = 'n8n-nodes-base.start';
export const WEBHOOK_NODE_TYPE = 'n8n-nodes-base.webhook';
export const CRON_NODE_TYPE = 'n8n-nodes-base.cron';
export const SET_NODE_TYPE = 'n8n-nodes-base.set';
export const FUNCTION_NODE_TYPE = 'n8n-nodes-base.function';
Node Categorization
Nodes are organized into a hierarchical structure of categories and subcategories to facilitate discovery and logical grouping in the workflow editor.
The diagram below illustrates the relationship between different node categories and their subcategories as defined in the node configuration files.
This diagram shows the main node categories and some of their subcategories.
Sources: Set.node.json:60, If.node.json:56, HttpRequest.node.json:60, ReadBinaryFile.node.json:31, Slack.node.json:6, Webflow.node.json:5, GoogleSheets.node.json:5
| Category | Description | Example Nodes |
|---|---|---|
| Core Nodes | Fundamental nodes for building most workflows. | Start, If, Set, Merge, HttpRequest |
Data Transformation | Nodes that modify or restructure data. | Set, Function, Merge, HtmlExtract, Xml |
Flow | Nodes that control the execution path of the workflow. | If, Merge, Cron, CompareDatasets |
Helpers | Utility nodes that perform common tasks. | HttpRequest, Webhook, NoOp |
Files | Nodes for reading and manipulating files. | ReadBinaryFile |
| Development | Nodes useful for developers and advanced use cases. | HttpRequest, Function, GraphQL, MongoDb |
| Communication | Nodes for interacting with communication platforms. | Slack, Mattermost |
| Data & Storage | Nodes for connecting to databases and data storage services. | Airtable, GoogleSheets, MongoDb |
| HITL | "Human in the Loop" nodes that require user interaction. | Slack |
Sources: Set.node.json, If.node.json, HttpRequest.node.json, Function.node.json, Slack.node.json, Airtable.node.json, MongoDb.node.json, ReadBinaryFile.node.json, CompareDatasets.node.json
Key Node Types
Nodes can be broadly classified by their function within a workflow, such as starting an execution, controlling the flow, or interacting with external services.
Trigger Nodes
Trigger nodes are special nodes that start a workflow execution. They can be activated manually, on a schedule, or by an external event (e.g., a webhook call).
A workflow can only be activated if it contains a trigger node. However, certain trigger types like manualTrigger or errorTrigger are not considered activatable for production environments.
Sources: packages/frontend/editor-ui/src/constants.ts:262-267, packages/frontend/editor-ui/src/constants.ts:272-278
Common Trigger Nodes:
- Start (
n8n-nodes-base.start): The default node for manual executions from the editor. - Webhook (
n8n-nodes-base.webhook): Listens for incoming HTTP requests to trigger the workflow. - Cron (
n8n-nodes-base.cron): Triggers the workflow on a recurring schedule defined by a cron expression. - Manual Trigger (
n8n-nodes-base.manualTrigger): A trigger for workflows that are called by anExecute Workflownode.
Flow Control Nodes
These nodes direct the flow of data through different branches of a workflow based on defined conditions.
- If (
n8n-nodes-base.if): Implements binary conditional logic. It evaluates incoming data against one or more conditions and routes it to either atrueorfalseoutput.
Sources: If.node.json:5-6
The following diagram illustrates the logic of an If node.
Merge (n8n-nodes-base.merge):* Combines data from multiple incoming branches into a single stream. It can be configured to wait for all branches to complete or to proceed as soon as data arrives from any branch.
Sources: Merge.node.json
- Compare Datasets (
n8n-nodes-base.compareDatasets): Compares two datasets to find items that are unique to each or present in both, useful for data synchronization tasks.
Sources: CompareDatasets.node.json
Data Transformation Nodes
These nodes are used to manipulate, reformat, or generate data within a workflow.
- Set (
n8n-nodes-base.set): Allows you to create, update, or remove fields in the JSON data of an item. It's a versatile node for simple data manipulation without writing code.
Sources: Set.node.json - Function (
n8n-nodes-base.function): Executes custom JavaScript code. This provides maximum flexibility for complex data transformations, allowing users to iterate over items and manipulate data structures in ways not possible with other nodes.
Sources: Function.node.json:5-6 - HTML Extract (
n8n-nodes-base.htmlExtract): Extracts data from HTML using CSS selectors. This is useful for web scraping.
Sources: HtmlExtract.node.json - XML (
n8n-nodes-base.xml): Parses XML data into JSON and vice-versa.
Sources: Xml.node.json
Example Workflow Snippet
The following JSON snippet shows a simple workflow that uses a ManualTrigger, a Code node to mock data, a Set node for transformation, and an HtmlExtract node to parse HTML content.
Sources: packages/nodes-base/nodes/HtmlExtract/test/workflow.dotNotation.json:4-105
{
"name": "http fix",
"nodes": [
{
"parameters": {},
"id": "5cfa67ba-caba-40f6-b0c4-b54015b28bf0",
"name": "When clicking \"Execute Workflow\"",
"type": "n8n-nodes-base.manualTrigger",
"typeVersion": 1,
"position": [300, 580]
},
{
"parameters": {
"jsCode": "return [ { \"html\": \"<html>...</html>\" } ];"
},
"id": "88a269af-c315-491c-b897-578cfb81268a",
"name": "Mock data",
"type": "n8n-nodes-base.code",
"typeVersion": 1,
"position": [520, 580]
},
{
"parameters": {
"extractionValues": {
"values": [
{
"key": "title",
"cssSelector": "h1"
}
]
},
"options": {}
},
"id": "ad74d9ea-adf3-42b1-87c8-be1096356096",
"name": "HTML Extract (top level)",
"type": "n8n-nodes-base.htmlExtract",
"typeVersion": 1,
"position": [960, 680]
}
],
"connections": {
"When clicking \"Execute Workflow\"": { "...": [] },
"Mock data": { "...": [] }
}
}
Conclusion
n8n nodes are the core components that provide the power and flexibility of the platform. Through a standardized definition structure (.node.json), a clear categorization system, and a wide variety of types—from triggers to flow control and data transformation—nodes enable users to build everything from simple automations to highly complex, multi-step workflows. Understanding the different types of nodes and their capabilities is essential for effectively leveraging n8n.