AI automation (n8n)

What is n8n? How it works, self-hosting and your first automations

11 min read Updated: Czytaj po polsku
What is n8n? How it works, self-hosting and your first automations

n8n is a workflow automation platform where you connect apps, APIs and AI models in visual flows built from nodes. You can use n8n’s managed cloud or self-host the free Community edition on your own server, and on paid plans you pay per full workflow run rather than per individual step.

What is n8n?

n8n (pronounced “n-eight-n”) is a tool for building automations that run on their own: they react to an event, process data and send the result wherever it needs to go. The name is short for “nodemation”, as founder Jan Oberhauser explains in the n8n GitHub repository. The repository has more than 210,000 stars (as of 18 November 2026).

Three things set it apart from Zapier or Make. You can host it yourself. You’re billed per execution rather than per operation. And you can drop into code at any point, so you’re never stuck when a pre-built integration falls short. The trade-off is a steeper learning curve: n8n expects you to understand data and APIs better than click-two-tiles tools do.

Glossary: the terms you’ll meet on day one

Term What it means in n8n
Workflow A set of connected nodes that automates one process, e.g. “new form lead goes to the CRM”.
Node A single step: fetch data, check a condition, call an API, prompt an AI model.
Trigger The starting node. It fires on a webhook, an email, a new spreadsheet row or a schedule.
Credentials Encrypted logins for external services (API keys, OAuth) that nodes use.
Expression A dynamic field value computed in JavaScript, e.g. the customer’s name from a previous step.
Execution One run of an entire workflow. Paid plans are priced on this number.
Sub-workflow A workflow called by another workflow, which lets you split big processes into reusable parts.
Cluster node A group of AI nodes: a root node (such as AI Agent) plus sub-nodes like a chat model, memory and tools.

Definitions follow n8n’s official key concept glossary.

How does n8n work in practice?

Every workflow starts with a trigger, and data flows on as a list of JSON items. Each node receives the previous node’s output and can filter it, branch it (IF, Switch), join it with another source (Merge) or loop over it. A real-world example:

  1. A visitor submits a form on your website and a Webhook node receives it.
  2. An IF node drops submissions without an email address.
  3. A Text Classifier node backed by an LLM tags the enquiry as quote request, complaint, partnership or spam.
  4. A CRM node (HubSpot, Pipedrive and so on) creates the contact with its category and source.
  5. A sales rep gets a Slack or Telegram ping, but only for quote requests.

While building, you can pin test data to a node so you’re not hammering external services with the same request. When the workflow is ready, you publish it and it runs in production. It’s also worth setting up a separate error workflow with an Error Trigger node so you hear about failures straight away.

What can n8n do with AI?

AI in n8n isn’t a single add-on. It’s several building blocks with different levels of autonomy, and you pick the one that fits the job:

  • Chains: Basic LLM Chain, Information Extractor, Text Classifier, Sentiment Analysis and Summarization Chain. They call a model in a fixed sequence with no memory, which suits invoice data extraction, email triage and summaries.
  • The AI Agent node is an agent that lives inside a workflow. You attach a chat model, memory and at least one tool, and the agent decides which tool to call.
  • Agents (Agent Builder) are standalone items next to your workflows: a model, instructions, tools, skills, a file-based knowledge base, memory and sub-agents. People reach them through chat, Slack or Telegram, and they can also run on a schedule. According to n8n’s docs they’re in Preview and available on self-hosted instances from n8n 2.32.3.
  • MCP in both directions. n8n agents can use tools from MCP servers, and n8n itself can act as an MCP server for clients such as Claude.
  • Control and safety. The Guardrails node checks text going into and coming out of a model and can swap personal data for placeholders. Human-in-the-loop pauses an agent until a person approves an email being sent or a record being deleted.

If you need an assistant that holds a conversation and takes actions across several systems, have a look at our AI agents for business.

n8n Cloud or self-hosted: which should you choose?

This is your first decision. n8n’s own guidance boils down to this: go cloud if you want to start now and skip infrastructure work, and self-host if you need full control and have someone to look after the server.

Criterion n8n Cloud Self-hosted Community Self-hosted Business / Enterprise
Licence cost From €20/month (Starter, billed annually) Free Business €667/month (billed annually), Enterprise on quote
Execution limit 2,500 (Starter), from 10,000 (Pro) No licence limit, only your server’s capacity 40,000 (Business), custom (Enterprise)
Servers, updates, backups Handled by n8n Your job Your job
Data location Frankfurt, Germany (EU) Wherever you host it Wherever you host it
SSO, environments, Git, workflow sharing Depends on plan Not included Included

Prices from the n8n pricing page (checked 18 November 2026, annual billing): Starter €20/month for 2,500 executions and 5 concurrent runs, Pro €50/month for 10,000 executions, Business €667/month for 40,000 executions (currently self-hosted only). Monthly billing costs more, since n8n says annual billing saves 17%. Companies with fewer than 20 employees can get 50% off Business. Every plan includes unlimited users and workflows. You can trial the cloud for 14 days with Pro features and a 1,000-execution cap.

The edition comparison describes Community as having “almost the complete feature set”. The main gaps are SSO, environments, Git-based version control, external secret stores and sharing workflows between users. Registering your instance with an email address unlocks folders, debug in editor and custom execution data for free.

Is n8n free and open source?

Free: yes, as the self-hosted Community edition. Open source: not technically. n8n uses the Sustainable Use License, a fair-code licence. The code is public and you can modify and extend it, but with three limits. You may use it only for internal business purposes or non-commercially. You may distribute it only free of charge for non-commercial purposes. And you may not remove licensing notices. Files with .ee. in their name fall under a separate Enterprise licence. n8n states plainly that it doesn’t call itself open source under the OSI definition.

The n8n licence FAQ is where it gets practical:

  • You can build automations for clients on your own instance, as long as clients can’t create or edit them. You can charge for building, setup, maintenance, training and consultancy, and use n8n behind the scenes in your own product, even when users connect their own accounts to automations you’ve built.
  • You can’t host n8n as a service where clients build their own workflows, or let end users configure workflow logic through a custom UI, the API, MCP or an AI agent acting on their behalf. Forking n8n into your own automation product, white-labelling it and using Enterprise features without a licence are also off the table.

The FAQ sums it up in one line: clients receive outputs, not access. That’s exactly how an automation agency works: it builds and runs the workflows, and the client gets the results.

How do you self-host n8n?

From n8n 3.0, Docker is the only supported way to self-host, and npm installs are no longer supported. As of November 2026 the stable line is still 2.x and 3.0 is in early access, so start any new install on Docker. Here’s the path:

  1. A server. n8n recommends 64-bit Linux for production. Any VPS will do, ideally in an EU data centre if you handle personal data of EU residents.
  2. Docker with Docker Compose v2. The installer checks that both are running.
  3. One command: curl -fsSL https://get.n8n.io | sh. Per the one-line setup guide, the script creates an n8n folder, writes the configuration with unique secrets into .env and starts n8n on localhost:5678.
  4. Domain, reverse proxy and TLS. Don’t expose n8n directly to the internet. Put NGINX or Caddy with a certificate in front of it and set N8N_HOST, N8N_EDITOR_BASE_URL and N8N_WEBHOOK_URL, otherwise your webhook URLs will be wrong.
  5. PostgreSQL. The bundled SQLite is fine for testing, but the production requirements recommend PostgreSQL, and SQLite isn’t supported at all in queue mode (the Redis-backed scaling setup).
  6. Backups. Back up the database and the n8n data directory. The data directory holds the key that encrypts your stored credentials, and without it a restored instance can’t read them.
  7. Register and update. Register the instance (Settings → Plan & usage) to unlock the free extras, and keep n8n up to date. Before moving to 3.0, run the report under Settings → Migration Report.

How does n8n count executions, and why does it matter?

On paid plans, only production executions count. n8n’s docs list what’s excluded: manual test runs in the editor, sub-workflow calls (only the parent counts), error-workflow runs, polls that find no new data, and malformed requests rejected before the workflow starts. Every incoming webhook, however, is a separate execution, even with an empty body.

This adds up fast. n8n’s own example: a schedule firing every 5 minutes means roughly 8,600–8,900 executions a month, more than three times the Starter allowance. Before you set something to check “every minute”, ask whether a webhook or a trigger that only fires on new data would do. For a full side-by-side with Make and Zapier, read n8n vs Make vs Zapier: pricing and limits compared.

Your first n8n automations: where to start

Pick a process that happens at least a few times a week, has a clear input and output, and won’t cause a disaster if it goes wrong once. Five proven starters:

  1. Form → CRM → notification. Webhook or n8n Form, then a CRM node and a Slack message. Good practice in field mapping, and you see the result immediately.
  2. Email attachments → Google Drive → spreadsheet. Gmail Trigger, Extract From File, Information Extractor (document number, amount, due date) and Google Sheets. Leave the totals check to a human.
  3. Inbox triage. Text Classifier assigns a category, and n8n labels the email and routes it to the right person.
  4. New Google Business Profile review → alert and draft reply. The Google Business Profile Trigger fires on a new review, and the model drafts a response for approval.
  5. Monday-morning report. A Schedule Trigger pulls data from Google Analytics or the Search Console API, the model writes three lines of commentary, and it all lands in your inbox.

For more ready-to-use scenarios across sales, finance and customer service, see AI automation for business: 15 practical examples.

Common beginner mistakes

  • No error workflow. An automation can fail silently for weeks before anyone notices leads have stopped reaching the CRM.
  • SQLite and no backups in production. Fine until the disk dies.
  • Port 5678 open to the world. The n8n editor holds the keys to every connected account, so protect it like your online banking.
  • API keys pasted into a Code node instead of credentials. They leak the first time someone exports the workflow.
  • No AI spending limits. A loop that accidentally calls a model a few thousand times won’t stop on its own. Set budget caps with your model provider.
  • One giant workflow. Split it into sub-workflows. They’re easier to test, and sub-workflow calls don’t use up your execution quota.

When is n8n the wrong choice?

If you only need to connect two apps and nobody on the team is technical, Zapier will get you there faster. If you want to give users of your SaaS product their own automation builder, you need a commercial licence from n8n, because the Community edition doesn’t allow it. And if no one will own the server, choose n8n Cloud or hand maintenance to a partner. Self-hosting without updates and backups isn’t a saving. It’s a liability.

Want n8n running in your business without setting up servers or learning it all from scratch? See how we deliver AI automation with n8n, or get in touch and we’ll suggest which processes to automate first.

Frequently asked questions

Is n8n free?

Yes. The self-hosted Community edition has no licence fee and no licence-imposed execution limit, so you only pay for the server and the time to maintain it. n8n Cloud is paid, starting at €20 a month billed annually as of November 2026, with a 14-day free trial.

Is n8n open source?

Not strictly. n8n uses the Sustainable Use License, a fair-code licence: the source is public and you can modify it, but commercial use is limited to internal purposes. That's why n8n doesn't describe itself as open source under the OSI definition.

Can I build n8n automations for clients and charge for it?

Yes. n8n's licence FAQ explicitly allows charging for building, setup, maintenance, training and consultancy. The condition is that clients can't create or edit workflows on your instance themselves: they get the outputs, not access to n8n.

Do I need to code to use n8n?

You can build simple automations without code by connecting ready-made nodes. In practice, though, it helps to understand JSON, API basics and a little JavaScript for expressions and the Code node. Without that, it's hard to build automations that cope with messy real-world data.

n8n Cloud or self-hosted: which is better for GDPR?

Both can be run in a GDPR-compliant way. n8n Cloud stores data on servers in Frankfurt, Germany, while self-hosting lets you choose the server location and keep full control of logs. Self-hosting gives you more control but also makes security, updates and backups your responsibility.

What's the difference between the AI Agent node and n8n agents?

The AI Agent node runs inside a workflow: you attach a model, memory and tools, and a trigger starts it. Agents built in the Agent Builder are standalone items alongside workflows that people chat with through chat or messaging apps, and they can run on a schedule. As of November 2026, agents are in Preview.

Sources

  1. n8n — Pricing
  2. n8n Docs — Choose how to use n8n
  3. n8n Docs — Compare editions
  4. n8n Docs — Community license
  5. n8n Docs — License FAQ
  6. n8n — Sustainable Use License (LICENSE.md)
  7. n8n Docs — Key concept glossary
  8. n8n Docs — AI Agent node
  9. n8n Docs — Build and manage agents
  10. n8n Docs — Guardrails node
  11. n8n Docs — Human-in-the-loop for tools
  12. n8n Docs — Try free then choose a plan
  13. n8n Docs — One-line setup
  14. n8n Docs — Production requirements
  15. n8n Docs — v3.0 Breaking changes
  16. n8n Docs — Understand executions
  17. GitHub — n8n-io/n8n

Need help with this?

We connect your tools — CRM, email, spreadsheets, store, accounting — into n8n workflows where AI reads, classifies and replies. You get hours back, not another app to babysit.