ToolDepth

n8n Self-Hosted Setup Guide: Run Automation for Pennies

Updated May 2026 · 10 min read
This article contains affiliate links. If you purchase through these links, we may earn a commission at no extra cost to you.

If you're running more than a few thousand automated tasks per month, you're probably overpaying. Here's the fix: self-host n8n on a $10/month VPS and run unlimited workflows.

I've been running n8n self-hosted for over a year across multiple projects. Here's exactly how to set it up — including the gotchas that the official docs won't tell you.

Why Self-Host n8n?

Simple question: would you rather pay $10/month for unlimited automations or $1,500/month for the same thing on Zapier? That's the n8n value proposition.

Beyond cost, self-hosting gives you:

  • Unlimited workflows — no per-task pricing
  • Data privacy — your data never leaves your server
  • Full control — any npm package, any API, any code
  • AI integration — native Claude, GPT, and LangChain nodes

What You'll Need

Item Cost Notes
VPS (Virtual Private Server) €5-10/month DigitalOcean, Hetzner, or any Linux VPS
Domain (optional) ~$10/year For HTTPS access — worth it
Docker Free Pre-installed on most VPS images

Step 1: Get a VPS

I recommend starting with a basic €5-10/month VPS from Hetzner or DigitalOcean. For n8n alone, you only need 1GB RAM and 1 CPU core. If you're running heavy AI workflows, go with 2GB+ RAM.

Get started with Hetzner

Reliable, affordable VPS hosting starting at €4/month. My go-to for self-hosted n8n.

Check Hetzner →

Step 2: Install n8n with Docker

SSH into your VPS and run:

# Pull and run n8n
docker run -d \
  --name n8n \
  -p 5678:5678 \
  -v n8n_data:/home/node/.n8n \
  -e N8N_SECURE_COOKIE=false \
  n8nio/n8n

After this, n8n will be running at http://your-server-ip:5678.

Step 3: Set Up HTTPS (Important)

Don't run n8n over plain HTTP in production. Use Nginx as a reverse proxy and let's encrypt for SSL:

# Install Nginx
sudo apt update && sudo apt install nginx -y

# Create config
sudo nano /etc/nginx/sites-available/n8n

Add this config:

server {
    server_name n8n.yourdomain.com;
    location / {
        proxy_pass http://localhost:5678;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
    }
}

Then enable SSL with certbot and enable the site.

Step 4: Production Hardening

Before you start building workflows, do these:

  • Set up backups — backup the n8n_data volume daily
  • Enable basic auth or SSO — don't leave n8n exposed without authentication
  • Configure environment variables — set N8N_ENCRYPTION_KEY for credential encryption
  • Set up monitoring — use UptimeRobot or similar to alert you if n8n goes down

Cost Comparison: Zapier vs Self-Hosted n8n

Monthly Volume Zapier Cost n8n Self-Hosted Cost Savings
10,000 tasks $1,500+/mo ~$10/mo 99% savings
50,000 tasks $3,000+/mo ~$10/mo 99%+ savings
100,000 tasks Custom (very expensive) ~$15/mo 99%+ savings

Start self-hosting n8n today

Download n8n free, open-source, and set it up on your own server. No limits, no per-task pricing.

Download n8n Free →
X in Link