
n8n is an open-source workflow automation tool that lets you connect apps, APIs, and services to automate tasks using a visual editor. It supports over 350 integrations including tools like Google Sheets, Slack, Notion and GitHub that allows you to build powerful workflows across platforms. n8n also enables creating AI agents by integrating Large Language Models (LLMs), giving you the ability to automate intelligent decision-making and actions.
Comparison of n8n, Zapier and Make
Feature | n8n | Zapier | Make |
---|---|---|---|
Type | Open-source, self-hostable | Proprietary, cloud-based | Proprietary, cloud-based |
Hosting Options | Self-hosted or cloud | Cloud only | Cloud only |
API & Webhook Support | Full, flexible | Yes, limited in free tier | Full, very flexible |
Pricing | Free (self-hosted), Paid (cloud) | Subscription-based | Usage-based (operations/minutes) |
Best For | Technical users | Non-technical users | Semi-technical users |
n8n has greater flexibility than Zapier and Make due to its open-source nature, which allows users to self-host and customize workflows.
n8n Cloud vs n8n Self-Hosted
Key features of n8n Cloud:
Hosted and maintained by the n8n team.
No setup or server management required.
Automatic updates, backups and scalability.
Paid plans based on usage and features.
Data flows through n8n's cloud infrastructure.
Easier for non-technical users or teams without DevOps.
NOTE
Use n8n Cloud if you want hassle-free and managed infrastructure.
Key features of n8n Self-Hosted:
Host it on your own server (e.g. Docker, local machine).
Requires manual installation, updates, and monitoring.
Handle security, backups and scaling.
Full control over your workflow and data.
Unlimited use of custom nodes, scripts and integrations.
Ideal for developers or teams with technical skills.
NOTE
Use n8n Self-Hosted if you want full control, privacy and customization.
In this blog post, I will use n8n Self-Hosted method. So, let's move on to setup n8n locally.
Setup n8n Locally
Step 1: Install NodeJS
Go to NodeJS official site to download and install the LTS version of NodeJS.
After NodeJS installation, verify in terminal
node -v
npm -v
You should see version numbers like v20.x.x
and 10.x.x
.
Step 2: Install n8n
npm install -g n8n
This installs n8n globally so you can run it from anywhere in your terminal.
Step 3: Start n8n
After n8n installation, run in terminal
n8n
Go to http://localhost:5678
in your browser.
The next step is to understand how workflows are structured. n8n workflows are made up of different types of nodes: Trigger Nodes to start a workflow, Core Nodes to perform key actions, Data Transformation Nodes to shape the data, and Flow Nodes to control logic and direction.
Trigger Nodes
Trigger nodes are the starting point of any workflow in n8n. They wait for a specific event like a webhook call, scheduled time, or chat message to activate the workflow. Without a trigger node, a workflow will not run automatically.
Trigger manually -> Start the workflow by clicking the “Execute Workflow” button in the editor—mainly used for testing.
On webhook call -> The workflow runs when it receives an incoming HTTP request at a custom webhook URL.
On a schedule -> Automatically triggers the workflow at set intervals or times using cron style scheduling.
On chat message -> The workflow starts when a message is received in a connected chat app like Telegram or Slack.

Core Nodes
Core nodes handle essential operations like sending HTTP requests, making API calls, managing sub-workflows, or pausing execution. They are commonly used across a wide range of workflows to connect with services and control execution flow.
- Webhook -> Starts a workflow when it receives an incoming request at a custom URL.
TIP
Set respond in Webhook node to Using 'Respond to Webhook' Node if you want to return data from other nodes by Response to Webhook node.
HTTP request -> Sends a request like
GET
andPOST
to an external API or website to fetch or send data.Respond to Webhook -> Sends a custom response back to the service or client that triggered the webhook.

Execute Sub-workflow -> Runs another workflow as a child process and optionally returns its result.
Wait -> Pauses workflow execution for a specific time or until a set condition is met. Useful for delaying actions, waiting on external input or preventing rate limiting when calling APIs or visiting websites.


Data Transformation Nodes
Data transformation in n8n involves the key nodes like Edit Fields (Set), Split Out, and Code. These nodes give you control over how data changes across your workflow.

- Edit Fields (Set) -> Add, change, or remove fields in your data.
userList
with array of data (John, Alex, Niko) stated in the JSON.

- Split Out -> Split an array of items into process one item at a time.
userList
transformed into a list with mutliple items.

- Code -> Write custom JavaScript to transform or manipulate data. In the Code node, there is a loop with the string process to form new field, greetings.

Flow Nodes
n8n includes flow control nodes like If, Switch, Filter, Merge, and Stop and Error to manage how data moves through a workflow. These nodes help structure logic and guide execution paths.
Here is the workflow uses set, split out and flow nodes to identify and process Promo Guests and Survey Users.


- If -> Checks if a condition is true or false. The If node is used to check if the data is empty.

TIP
You can apply the data by dragging it from the input and dropping it into the field.
- Stop and Error -> Stops workflow execution and throws a custom error message for handling exceptions.

- Switch -> Routes items based on multiple cases. The Switch node is used to identity whether the user type is
paidUser
,normalUser
orguest
.

- Filter -> Keeps only the items that match specific conditions. For example, filter out
paidUser
with active points > 30.

- Merge -> Combines data from two or more branches. In this case, the merge node combined the filtered
paidUser
andnormalUser
.

Integration Support for Popular Apps
n8n provides integration with popular apps like Google, Slack, Telegram, Airtable, Trello and Notion through various pre-built nodes, making automation fast and easy. For apps not yet directly supported, you can still connect using the HTTP Request node to call external APIs and extend functionality.

AI Agent
n8n AI Agent node allows you build intelligent workflows powered by Large Language Models (LLMs), enhanced with memory and tools. It behaves like an autonomous agent that can reason, decide, and act through tools. The key components:
Model - the brain of the agent, responsible for understanding prompts, reasoning, and deciding what actions to take.
Memory - stores past interactions during a workflow run, allowing the agent to maintain context and coherence.
Tools - external functions the agent can use to perform services or actions and retrieve information.
Here is an example of n8n AI agent that retrieves the current weather. It uses OpenAI as the model, Simple Memory for context and OpenWeatherApp tool for the weather data.

Setup the credentials to integrate apps like OpenAI chatGPT or other services.

Set model define
to the city field in OpenWeatherMap to avoid manually entering city names.

Click Open chat button and test the AI agent by asking a question like What is the weather of Ipoh today?
. The result will be displayed in the chat and the AI agent's flow log will appear on the right side of the chat.

Webhook Security Best Practices
Webhook security is important to prevent unauthorized access and misuse of workflows. To secure your webhook endpoints in n8n:
- Webhook Auth -> Add authentication to provide a layer security for the workflow.
n8n webhook supports authentication methods like Basic Auth, Header Auth and JWT Auth. Here is an example of a webhook using Header Auth.

In this example, the name is set as n8n-header, while 6 mixed characters are set in the value field.

Postman is used to test the webhook endpoint and a 200 OK response is returned when the correct header auth is provided.

A 403 Forbidden response with the message 'Authorization data is wrong!' is returned if the header auth is missing.

- Webhook Options -> Optionally use CORS or whitelist IPs to filter incoming requests.

Real-World Use Case Ideas
🔗 API Aggregator - pull data from multiple APIs, combine it, and send or store the result. n8n nodes used:
HTTP Request – to call different APIs.
Code – to transform or format the data.
Merge – to combine data streams.
Google Sheets / Notion – to output combined data.
📥 Email Collector - collect emails from a web form, store them in Google Sheets, and send a confirmation email. With the elements:
Webhook – receives form submissions.
Code – to structure or clean incoming data.
Google Sheets – adds new row with email and timestamp.
📊 Daily Digest Bot - send daily reports (For ex: from Google Sheets or APIs) to Slack or Telegram. By the following nodes:
Cron – triggers workflow daily.
Google Sheets / HTTP Request – fetch data.
Code – format data into a readable message.
Slack / Telegram – send message to a channel or group.
TIP
Start by breaking down the process into clear steps, then build it node by node with frequent testing and finally review the entire flow to optimize logic, handle errors, and ensure security.
🤖 AI Automation - use LLMs to summarize, rewrite, or generate content. n8n nodes involved:
AI Agent – Set custom prompt in its System Message option.
Google Sheets / Notion – to provide input or store output.
🧠 Personal Productivity Bot - automate repetitive tasks, reminders, and note-taking for personal use. n8n nodes used:
Cron – daily or weekly check-ins.
Notion / Google Calendar – fetch tasks or events.
AI Agent – auto-prioritize or summarize tasks.
Slack / Email – send reminders or summaries.
Conclusion
This guide highlights some of the key features and practical uses of n8n, but there's still so much more to explore. From advanced integrations to custom automation strategies, n8n is packed with capabilities that go far beyond what has been covered. The best way to truly understand its potential is to dive in, experiment with different workflows and see how it can fit into your own unique use cases.