Run n8n 24/7 on a £5 server, with HTTPS
Your n8n on your PC stops when the laptop sleeps. Move it to a small rented server with your own address, a real HTTPS padlock, webhooks other apps can reach, and nightly backups. Docker, Caddy and Ubuntu, set up properly, one step at a time.
- Nightly backups, a monthly update routine, and a restore you've actually practised
- A small server (VPS) with at least 2GB of RAM. Monthly prices before VAT (they change, so check the links): Hetzner ↗ CX23 (2 vCPU, 4GB) €5.49 plus €0.50 for the IPv4 address ↗, so €5.99, when it's in stock. Vultr ↗ Regular Performance: 2GB for $10, 1GB for $5. DigitalOcean ↗ Basic: 2GB for $12, 1GB for $6. All bill by the hour, so a server you delete after an hour costs pennies.
- A domain name. One you already own is fine: you only add a subdomain. New ones on Porkbun ↗: .co.uk $5.66 a year, .com $11.08 a year.
- n8n basics. Do Your own Zapier first. This mission moves n8n to a server; it doesn't re-teach workflows.
- The terminal. You'll type commands on your PC and on the server. New to it? The Terminal survival kit covers everything used here.
- A password manager for the server details and n8n's encryption key. KeePassXC is free.
- About 2 hours. A chunk of that is waiting for downloads and DNS.
Rent a small server and log in with a key
A VPS is a computer in a data centre that never sleeps. Logging in with a key instead of a password shuts out the bots that try passwords on every server, all day.
What you're buildingOne small server that never sleeps. Caddy sits at the front and handles HTTPS, n8n runs behind it, and a separate runner handles Code nodes. By the end, any app on the internet (a form, Stripe, a Telegram bot) can trigger your workflows, even with your laptop shut.

The finished setup. Only Caddy faces the internet; n8n's own port is reachable from the server itself, nothing else. Before you pay for anything, the licence. n8n's self-hosted version uses the Sustainable Use License. Its licence FAQ ↗ says you can use it free to run your own business, for personal projects, and to build automations for clients, charging for setup, maintenance and training. You can't host n8n as a service where clients build their own workflows, white-label it, or fork it into your own automation product. If you want to sell n8n work, read the licence step of Automate a small business's admin too: it covers whose name the server should be in.
Now make an SSH key on your PC. Windows 10 and 11 and macOS already include the
sshtools. Press Enter to accept the suggested file, then type a passphrase (it protects the key if your laptop is stolen):Terminalssh-keygen -t ed25519 -C "n8n-server"That made two files. The one ending in .pub is your public key, which is safe to give to the server company. The other one is private: never paste it anywhere. Show the public one:
Windows (PowerShell)Get-Content $HOME\.ssh\id_ed25519.pubMac / Linuxcat ~/.ssh/id_ed25519.pubPick a provider and plan from the list in What you need. Get 2GB of RAM or more: n8n, its Code node runner and Caddy all share it. Hetzner's CX23 is the cheapest 4GB option, but its Cost-Optimized plans are sometimes out of stock in some locations, so have a second choice ready. When you create the server, choose:
- Image: plain Ubuntu 24.04 LTS or 26.04 LTS, not a one-click "Docker" app. Both are on Docker's supported list, and you'll install Docker from Docker's own repository in step 4.
- Location: close to you or your users. London, Amsterdam, Frankfurt, Nuremberg or Helsinki all work well from the UK.
- Authentication: SSH key. Paste the whole
ssh-ed25519 ...line from above. - Backups: optional, but worth it. Hetzner and DigitalOcean both sell automatic daily or weekly snapshots for a percentage of the server price.
TipWill it hold people's personal data, like form submissions or customer emails? Then you're responsible for it under UK GDPR. An EU or UK location keeps things simple, and DigitalOcean and Vultr both have London data centres.Copy the server's public IPv4 address from the dashboard. We'll use
203.0.113.10as an example: swap in yours everywhere. Log in as root:Terminalssh root@203.0.113.10The first time, ssh asks
Are you sure you want to continue connecting (yes/no/[fingerprint])?. Type yes. That records the server's identity, so ssh can warn you if it ever changes.
root@your-server:~#. You're on the server.If it breaks'Permission denied (publickey)' + 3 more
'Permission denied (publickey)'
'ssh' is not recognised (Windows)
'Connection timed out'
'WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!'
ssh-keygen -R 203.0.113.10 and connect again. If you didn't rebuild anything, stop and find out why.