Self-hosting n8n is one of the smartest moves you can make if you’re tired of paying per task on Zapier or Make. A few hundred automations in on those platforms and you’re easily spending $100+ a month — for workflows that, frankly, shouldn’t cost that much. n8n changes that equation entirely.
It’s open-source, fair-code licensed, deeply extensible, and genuinely powerful. Unlike the SaaS alternatives, the self-hosted version doesn’t charge per task. You pay for a server, and that’s it. The catch? You have to pick that server yourself — and set it up correctly.
This guide is for people who are ready to make the switch but aren’t sure where to start. What kind of machine does n8n need? Which hosting provider should you go with? Do you need Docker? What about SSL, backups, and performance?
Let’s get into it.
Table of Contents
What n8n Actually Needs to Run
Before you spin up a droplet or reserve a cloud instance, it helps to understand what you’re actually hosting.
n8n is a Node.js application. It runs workflows on triggers — webhooks, schedules, or manual events — and executes sequences of “nodes” that can hit APIs, transform data, read from databases, send emails, and more. Under the hood, it needs a few things:
- A Node.js runtime (n8n officially supports Node 18+)
- A database — SQLite by default (fine for personal use), PostgreSQL for anything serious
- Persistent storage for execution logs, credentials, and uploaded files
- Enough RAM to run concurrent workflows without choking
The baseline is modest. n8n’s own docs suggest 1 vCPU and 512MB RAM minimum, but that’s genuinely the floor — for testing, not production. Real-world use is another story, and we’ll get to sizing in a moment.
The good news: n8n is not a resource hog by default. It doesn’t need a beefy machine. A $6/month VPS can run it just fine for personal or small business use. The trick is knowing when you need to upgrade.
Your Hosting Options, Laid Out Honestly
There’s no single “right” answer here, but there are definitely wrong ones for specific situations. Let’s break down the main categories.
VPS (Virtual Private Server)
This is what most people use, and for good reason. A VPS gives you a slice of a physical server — dedicated RAM, CPU, and storage — at a predictable monthly cost. You get root access, full control over the environment, and the ability to run Docker, configure firewalls, and install whatever you need.
Good for: Most users. Developers, small teams, freelancers automating client work.
Not ideal for: Extremely high-volume workflows with thousands of executions per hour.
Dedicated Server
A dedicated server means the whole physical machine is yours. More power, more cost, zero resource sharing with other tenants.
Most n8n users will never need this. If you’re running 50,000+ workflow executions a day with complex branching and external API calls, maybe. But honestly, even aggressive n8n setups rarely justify dedicated hardware.
Home Server / Raspberry Pi / Local Machine
Running n8n on a Raspberry Pi 4 or an old PC is entirely possible — and plenty of homelab enthusiasts do exactly this. The upside is zero ongoing cost. The downside is uptime: your home internet going down, your router restarting, or a power blip takes your automation with it.
If your workflows are non-critical or purely internal (LAN-only), a home server is a legitimate option. For anything involving webhooks from external services (Stripe, GitHub, Slack), you need a public-facing server with reliable uptime.
Managed Cloud (AWS, GCP, Azure)
You can run n8n on AWS EC2 or Google Cloud Compute. It works. But unless your company already lives in those ecosystems, the complexity-to-value ratio is rough for a solo operator or small team. IAM policies, VPC setup, security groups, billing surprises — it adds up, and not just in dollars.
There’s a reason most n8n self-hosters gravitate toward simpler VPS providers.
How to Choose the Right Server Size
This is where most guides get vague. “It depends on your workload” — yes, obviously. But let’s be more specific.
Here’s a practical sizing framework:
Personal / Solo Use (< 50 workflows, occasional triggers)
- 1 vCPU, 1–2 GB RAM, 20 GB SSD
- SQLite works fine
- A $6–$10/month VPS is more than enough
Think: personal productivity automations, syncing tools, Notion integrations, email filters. You’re not running hundreds of executions per hour.
Small Business / Team Use (50–500 active workflows, moderate volume)
- 2 vCPU, 4 GB RAM, 40–80 GB SSD
- Switch to PostgreSQL
- $20–$40/month range on most providers
Here you’re dealing with real business processes — CRM syncs, invoice automation, Slack notifications, maybe some light data pipelines. Concurrent executions start to matter.
Production / High-Volume (500+ workflows, frequent execution, multiple users)
- 4+ vCPU, 8+ GB RAM, 100+ GB SSD (or separate DB server)
- PostgreSQL is mandatory
- Consider separating the database onto its own instance
- $60–$100+/month, or scaling up dynamically
At this scale, you’re likely running n8n in queue mode (using Redis as a task broker), which distributes workflow execution across worker processes. This is where the architecture starts mattering as much as raw hardware.
A quick rule of thumb: If a single workflow execution consumes significant compute (PDF generation, image processing, large API payloads), treat each execution as heavier than average and size up accordingly.
Top VPS Providers for n8n: A Practical Comparison
There are dozens of VPS providers out there. Here are the ones that consistently come up in the n8n community, and for good reason.
Hetzner Cloud (⭐ Community Favorite)
Hetzner is a German provider with data centers in Europe and the US. It’s remarkably cheap for what you get — a CX21 (2 vCPU, 4 GB RAM, 40 GB SSD) costs around €4.55/month at the time of writing. The performance-to-price ratio is hard to beat.
The UI is clean, snapshots are built in, and the network performance is solid. If you’re in Europe or don’t mind European data residency, Hetzner is the default recommendation for self-hosted n8n.
Downside: US data center options are more limited. Some compliance-sensitive use cases need US-only hosting.
DigitalOcean
DigitalOcean has been the default “developer-friendly VPS” for years. Their Droplets are easy to spin up, the documentation is excellent, and they have a large community of users who’ve done exactly what you’re trying to do.
A 2 GB RAM / 1 vCPU Droplet runs $12/month. Not as cheap as Hetzner, but the UX and marketplace (including a one-click n8n app) make it genuinely fast to get started.
Best for: People who want guardrails and good documentation, not just raw power.
Vultr
Vultr sits somewhere between Hetzner and DigitalOcean. Competitive pricing, global data center coverage (25+ locations), and a clean control panel. Their High Frequency Compute instances use NVMe storage, which matters if you’re doing a lot of read/write with workflow execution data.
$12–$24/month for a solid n8n setup.
Linode / Akamai Cloud
One of the oldest VPS providers still going strong. Reliable, well-documented, and with a pricing model that’s straightforward. Slightly less popular in the n8n community than Hetzner or DO, but technically solid.
OVHcloud
OVH is a European giant with very competitive pricing on VPS and dedicated servers. Their cheapest VPS tiers are occasionally too constrained (1 GB RAM can be tight), but their mid-tier VPS plans offer excellent value. Worth considering if you’re price-sensitive and in Europe.
The OS and Stack Question
Once you’ve picked a provider, you need to choose what to actually install.
Operating System: Ubuntu 22.04 LTS
Just use Ubuntu 22.04 LTS. It’s the most widely supported, has the most documentation, and n8n-specific deployment guides almost universally target it. Debian works too if you prefer it, but Ubuntu is the path of least resistance.
Docker vs. Bare Metal Install
Docker is the right choice for almost everyone. Running n8n in a Docker container means:
- Upgrades are one command:
docker pull n8nio/n8n:latest && docker compose up -d - It won’t conflict with other services on the same server
- You can pair it with a reverse proxy (Traefik or Nginx Proxy Manager) easily
- Rollback is straightforward if an update breaks something
The docker-compose setup for n8n + PostgreSQL + Traefik is well-documented and takes about 30 minutes to set up from scratch.
Bare metal (npm install) works, but means you’re managing the Node.js version, PM2 or systemd process management, and manual update workflows yourself. There’s no compelling reason to do this unless you have specific constraints.
Platform Abstractions: Coolify, Caprover, Portainer
If you want a bit more hand-holding with Docker deployments, tools like Coolify and Caprover give you a self-hosted Heroku-like experience. You can deploy n8n through a UI, manage environment variables visually, and get built-in SSL handling.
Coolify in particular has grown a strong following in the self-hosting community. It’s free, open-source, and makes multi-app server management much less painful.
The trade-off is another layer of abstraction — one more thing to maintain and troubleshoot. For advanced users comfortable with Docker Compose, the extra layer often just adds noise.
Networking, Domains, and SSL
n8n needs to be reachable over HTTPS for webhooks to work. Here’s the short version of how to make that happen:
- Point a domain (or subdomain) at your server IP. Something like
n8n.yourdomain.com. An A record in your DNS, pointing at your VPS IP. Propagation takes a few minutes to a few hours. - Set up a reverse proxy. Nginx or Traefik sit in front of n8n, handle SSL termination, and forward traffic to the n8n container on port 5678.
- Get a free SSL certificate via Let’s Encrypt. If you’re using Traefik, this is automatic. With Nginx, Certbot handles it in two commands.
The whole process, if you follow a good guide, takes under an hour. There’s no reason to pay for an SSL certificate — Let’s Encrypt is trusted everywhere and auto-renews.
One thing to configure carefully: your webhook URL. In n8n’s environment variables, set N8N_HOST, N8N_PORT, N8N_PROTOCOL, and WEBHOOK_URL correctly, or external services calling your webhooks will get confused.
Storage: What Most Guides Skip
Here’s something that catches people off guard: execution data storage.
By default, n8n stores the full input and output of every workflow execution in its database. For simple automations, this is fine. For workflows processing large JSON payloads, files, or high volumes of data, this database grows fast — and it slows things down.
A few things to do proactively:
Switch to PostgreSQL from the start. SQLite is fine for testing but degrades noticeably once you have thousands of executions stored. PostgreSQL handles concurrent reads/writes much better.
Configure execution data pruning. n8n has environment variables to automatically delete execution records older than X days or beyond X count. Set these early:
EXECUTIONS_DATA_PRUNE=true
EXECUTIONS_DATA_MAX_AGE=168 # hours (7 days)
Separate your database server (at scale). If you’re running a busy instance, the database and the n8n app competing for RAM on the same machine is a real bottleneck. Moving PostgreSQL to a managed database (like DigitalOcean Managed Postgres or even a separate VPS) can significantly improve stability.
For file storage (binary data, uploaded files in workflows), n8n supports S3-compatible storage backends. If your workflows handle files regularly, pointing n8n at an S3 bucket or a Hetzner Object Storage bucket keeps your VPS disk usage predictable.
Backups and Disaster Recovery
The most boring section. Also the one you’ll regret skipping.
What you need to back up:
- Your PostgreSQL (or SQLite) database — this contains all your workflows, credentials, executions
- Your
.envfile anddocker-compose.yml— your configuration - Any custom node modules or local files
How to back it up:
For PostgreSQL, a daily pg_dump piped to a compressed file, then synced to an S3 bucket or external storage, covers you for most disaster scenarios. A simple cron job can do this:
bash
0 3 * * * pg_dump -U n8n n8n | gzip > /backups/n8n_$(date +\%F).sql.gz
For your config files, most VPS providers offer snapshot functionality. A weekly server snapshot is a good safety net for configuration drift.
Test your backups. Spin up a test instance and restore from a backup at least once. The backup you’ve never tested isn’t really a backup — it’s a hope.
Is Cloud-Hosted n8n Ever Worth It?
n8n offers a cloud-hosted version (n8n.io Cloud) starting around $24/month for the Starter plan. It’s managed — no server setup, automatic updates, built-in SSL. Worth considering if:
- You’re not technical and the server setup is a genuine barrier
- Your team has no DevOps capacity at all
- You’re doing a quick proof-of-concept before committing to self-hosting
But let’s be real: the whole value proposition of n8n is that you can self-host it for a fraction of the cost of Zapier. Paying $24/month for the managed version starts to undercut that logic. And at Starter tier, you’re still capped on workflow executions.
For anyone comfortable with a Linux terminal and a few hours of setup time, self-hosting is almost always the better call financially.
Making the Call
Here’s a decision framework to summarize everything above:
| Situation | Recommendation |
|---|---|
| Solo / personal automation | Hetzner CX21 or DO $12 Droplet, Docker + SQLite |
| Small business, team of 2–10 | Hetzner CX31 or DO 4GB, Docker + PostgreSQL |
| Growing team, heavy workflows | 4+ vCPU VPS, PostgreSQL on separate instance, queue mode |
| Non-technical user / quick start | n8n.io Cloud Starter plan |
| Homelab / non-critical internal use | Raspberry Pi 4 or spare PC |
Final Thoughts
Self-hosting n8n isn’t hard — but it does reward thoughtfulness upfront. Picking the right server size, the right database, and setting up proper backups from day one saves you a painful migration later when your automations have become business-critical.
The default path for most people: grab a Hetzner VPS, install Docker and Docker Compose, follow the official n8n Docker Compose guide, point a subdomain at it, and you’re up in an afternoon. From there, iterate.
The beauty of self-hosting isn’t just the cost. It’s the control. Your data stays yours. Your workflows aren’t throttled by someone else’s pricing model. And when n8n releases a new version with a feature you actually want, you can update on your schedule — not theirs.
That’s worth an afternoon of setup.




