How to Self-Host n8n on a VPS (Step-by-Step with Hostinger)
Run n8n on your own VPS with unlimited workflows and executions. Step-by-step setup with Hostinger's n8n template, custom domain, updates and backups.
This post explains how to self-host n8n on a VPS. n8n is a workflow automation tool, similar to Zapier or Make, that connects apps, APIs and AI models with a visual editor. You can use it in n8n’s paid cloud, or run the free Community edition on your own server.
Self-hosting is the cheaper option once you run more than a handful of workflows, because a self-hosted n8n has no limit on workflows or executions. The only limits are the CPU and memory of your server. In this guide I set up n8n on a Hostinger VPS using its ready-made n8n template, point a custom domain at it, and cover the updates and backups you are now responsible for.
This post contains affiliate links. See our affiliate disclaimer.
Highlights:
- Unlimited workflows and executions on the free Community edition.
- n8n pre-installed in Docker, so no manual Docker setup.
- Works with a free subdomain or your own domain.
- About 10 minutes from purchase to your first workflow.
Self-Hosted n8n vs n8n Cloud
Before you start, make sure self-hosting is the right choice. n8n’s own documentation is clear that self-hosting requires technical knowledge: you install, secure, update and back up the server yourself.
| Self-hosted Community edition | n8n Cloud | |
|---|---|---|
| Workflows and executions | Unlimited (limited by your server) | Limited by plan |
| Cost | Your VPS only | Monthly subscription |
| Updates and backups | Your job | Handled by n8n |
| SSO, environments, Git version control, log streaming | Paid license only | Higher plans only |
| Setup | Server required | None |
If you only need a few simple workflows and don’t want to manage a server, n8n Cloud is the easier choice. If you want to run many workflows, AI agents or long-running jobs without paying per execution, self-hosting is worth it.
What You Need
- A VPS with at least 4GB of RAM. n8n itself is light, but workflows that process files, large JSON responses or AI calls use more memory. Hostinger’s KVM 1 (1 vCPU, 4GB RAM, 50GB NVMe) is enough for personal use; KVM 2 (2 vCPU, 8GB RAM) is the safer choice if you plan to run many workflows at once or add a database or other apps on the same server.
- A domain name (optional). You can start on the free subdomain Hostinger gives your VPS and add your own domain later.
- About 10 minutes.
At the time of writing, Hostinger’s KVM 1 costs $6.49/month and KVM 2 $8.99/month on a 24-month term, renewing at $11.99 and $14.99/month. Shorter terms cost more per month.
Step 1: Buy a VPS and Choose the n8n Template
- Open Hostinger’s n8n VPS hosting page and pick a plan.
- During checkout, choose a server location close to you or to the services your workflows call most. Latency matters less for automation than for websites, so any nearby region is fine.
- When asked for an operating system, choose the n8n template (listed as “Ubuntu 24.04 with n8n”). Hostinger also offers “n8n with queue mode” for heavy workloads and “n8n with 100+ pre-made workflows”; the plain template is the right start for most people.
- Set a strong root password and finish the purchase.
If you already have a Hostinger VPS, you can switch it to the n8n template instead: go to VPS, click Manage next to your server, open OS & Panel > Operating System, search for n8n, and click Change OS. Note that changing the OS erases everything on the server.
Step 2: Open n8n and Create the Owner Account
Setup takes a few minutes. When it finishes:
- Go to the VPS Overview page in hPanel and click Manage App. n8n opens in a new tab.
- n8n asks you to create the owner account: enter your email, name and a strong password. This is the admin account for your instance.
- Skip or fill in the short survey, and you land in the workflow editor.
Right after logging in, open Settings > Personal and turn on two-factor authentication. Your n8n instance is on the public internet, and it will soon hold API keys for your other accounts.
Step 3: Use Your Own Domain (Optional)
A custom domain such as automation.yourdomain.com is easier to remember and is required by some OAuth apps for callback URLs.
- In your domain’s DNS settings, add an A record for the subdomain (for example
automation) pointing to your VPS’s IP address, shown on the VPS Overview page. - Wait for DNS to update (usually a few minutes).
- Update n8n’s host settings so it builds webhook and OAuth URLs with the new domain, and get an SSL certificate for it.
After changing the domain, check that webhook URLs in the editor use the new address. If they still show the old hostname, the environment variables were not picked up and the container needs a restart.
Step 4: Build a Test Workflow
To confirm that everything works, including outbound connections and the scheduler:
- Click Create Workflow.
- Add a Schedule Trigger set to every minute.
- Add an HTTP Request node that calls a public API, for example
https://api.github.com. - Click Execute Workflow, check the output, then activate the workflow and wait two minutes.
- Open Executions to confirm it ran on schedule, then deactivate it.
Step 5: Keep n8n Updated
n8n releases updates often, and a self-hosted instance does not update itself. The template runs n8n in Docker, so updating means pulling the new image and recreating the container. Connect to your server over SSH (the Browser terminal in hPanel works too) and run:
cd /path/to/compose/directory
docker compose pull
docker compose down
docker compose up -d
Read the n8n release notes before major version updates, as they sometimes include breaking changes.
Step 6: Back It Up
Your workflows and saved credentials live on the VPS, so losing the server means losing them. Use at least two of these:
- VPS snapshots or backups in hPanel, before every update.
- Export workflows from the n8n editor (or with the n8n CLI) to a Git repository or cloud storage.
- Keep a copy of your encryption key. n8n encrypts saved credentials with it, and without it a restored database cannot decrypt your credentials.
Security Checklist
- Turn on two-factor authentication for every n8n user.
- Use SSH keys instead of the root password, and keep the root password long and unique.
- In Hostinger’s VPS Firewall, allow only the ports you need (SSH, HTTP and HTTPS).
- Don’t share your owner account; invite other users with their own logins instead.
Is Hostinger a Good Place to Host n8n?
What works well: the one-click n8n template removes the hardest part of self-hosting, the plans are cheap for the RAM you get, and KVM 1 is enough for most personal automations.
What to watch out for: the lowest price needs a 24-month prepayment and goes up at renewal, so compare the total cost over the full term. Hostinger’s support is chat-based, and user reviews of its response times are mixed. You are also the administrator: Hostinger keeps the server running, but updates, backups and n8n errors are up to you.
If you prefer to set everything up yourself, any VPS with 4GB of RAM and Docker will run n8n; Hostinger’s advantage is mainly the template and the price.
Final Thoughts:
Self-hosting n8n makes sense as soon as execution limits or cloud pricing start to hold you back. With Hostinger’s n8n template, the setup is mostly clicking through checkout and creating your owner account. The real work comes afterwards: turn on two-factor authentication, keep n8n updated and back it up before every update, and a single small VPS can run all of your automations.