PROGRAM ZERO 18-month live AI, LLM & full-stack programme · ₹89,999 or ₹7,500/month · Starts 9 January 2027
Explore Program Zero →
Careers Ninza — business and startup leadership training
JOIN ZERO NINZA KIDS
JOIN ZERO NINZA KIDS
See all programs → Free live masterclass → Guides & articles → Newsletter →
Careers Ninza
AI & AUTOMATION 6 min read · Updated 3 November 2026

Self-hosting n8n on a VPS in India: setup, security, backups and what it really costs

Self-hosting n8n gives you unlimited executions, data control and low running costs, in exchange for maintenance responsibility. This guide covers choosing a server, Docker setup, HTTPS, security, backups, updates and when cloud is the better choice.

CN
Careers Ninza AI faculty
Careers Ninza · Kolkata, India
Learn this live in our No-Code Agentic AI Development course

Self-hosting n8n means running it on your own server, usually a small VPS with Docker, a PostgreSQL database and HTTPS through a reverse proxy. You get unlimited workflow executions and control over where data lives, but you take on security, backups and updates. For businesses running many workflows, it is often the most cost-effective option.

Self-hosting is module ten of No-Code Agentic AI Development (deployment, measurement and rollout), and students deploy their own instance. This guide gives the overview; always follow the current n8n hosting documentation for exact commands, because they change between versions.

Should you self-host or use n8n Cloud?

Factorn8n CloudSelf-hosted
SetupMinutesAn hour or two for someone comfortable with Linux
MaintenanceHandled by n8nYour responsibility
Cost modelPlan by executionsServer cost; no execution limits for internal use
Data locationn8n’s cloudYour server, including Indian data centres
ScalingBy planBigger server or queue mode with workers
Best forBeginners, low volume, no IT supportMany workflows, high volume, data control

The Sustainable Use License allows free self-hosting for internal business use. If you plan to offer n8n as a service to others or embed it in a product, check the license terms and enterprise options.

What server do you need?

—Small business, a few dozen workflows: 2 vCPU, 4 GB RAM, 40 GB SSD is comfortable.
—Heavier AI or file processing: 4 vCPU, 8 GB RAM, more storage.
—High volume: separate database, Redis and worker processes in queue mode.
—Location: a data centre in India (Mumbai, Bengaluru, Chennai, Delhi NCR) for lower latency and data residency preferences.

Entry-level VPS plans from Indian and global providers often cost in the range of a few hundred to a couple of thousand rupees a month for this size, depending on provider and specifications.

What are the main setup steps?

1Prepare the server: update the OS, create a non-root user, enable a firewall allowing only SSH (ideally key-based) and HTTPS.
2Install Docker and Docker Compose.
3Point a subdomain such as automation.yourcompany.in to the server.
4Create a Compose file with n8n, PostgreSQL and a reverse proxy (Caddy, Traefik or Nginx) that obtains HTTPS certificates automatically.
5Set environment variables: host and protocol, webhook URL, timezone Asia/Kolkata, database connection and a strong encryption key.
6Start the stack, create the owner account and test a webhook from outside.
# excerpt of key n8n environment settings (values are examples)
N8N_HOST=automation.yourcompany.in
N8N_PROTOCOL=https
WEBHOOK_URL=https://automation.yourcompany.in/
GENERIC_TIMEZONE=Asia/Kolkata
DB_TYPE=postgresdb
N8N_ENCRYPTION_KEY=<long random secret, stored safely>

Back up the encryption key separately. n8n uses it to encrypt saved credentials; if you lose it, restored databases cannot decrypt your API keys and passwords.

How do you secure a self-hosted instance?

—HTTPS only; no plain HTTP access.
—Strong owner password and two-factor authentication where supported; limit user accounts.
—Firewall: expose only the reverse proxy; keep the database private.
—Keep the OS, Docker images and n8n updated; subscribe to security notices.
—Protect webhooks with authentication or secret tokens where possible.
—Use least-privilege credentials for connected apps.

How should backups work?

1Daily automated PostgreSQL dumps, kept for at least 14 to 30 days.
2Off-server copies to object storage or another location.
3Regular export of workflows as JSON (n8n’s CLI or a workflow that exports workflows).
4The encryption key stored in a password manager.
5A tested restore: actually restore to a test server once a quarter.

How do you update n8n safely?

Read the release notes for breaking changes, back up first, update the Docker image tag in a test environment if you have one, then in production during a quiet period, and run your key workflows to confirm. Pin specific versions rather than always pulling "latest" so updates happen when you choose.

When do you need queue mode?

By default n8n runs executions in the main process. When volume grows, or long AI and file workflows slow everything down, queue mode separates the main instance from worker processes using Redis, so you can add workers to handle more executions in parallel. Most small businesses never need it; agencies and high-volume operations eventually do.

Illustration: monthly cost comparison for a sample business running 30 workflows
Self-hosted VPS (4 GB RAM)about ₹1,500
Managed cloud automation planabout ₹4,500

Source: Careers Ninza illustration; real prices vary by provider, plan, exchange rate and volume. Self-hosting also needs maintenance time.

What are the limits of self-hosting?

Someone must own the server: updates, monitoring, backups and incident response. If nobody in the business can do that, cloud is safer. Downtime on a self-hosted instance means missed webhooks and delayed workflows, so set up uptime monitoring and alerts from day one.

What does a production-ready Compose setup include?

The structure of a typical self-hosted stack (simplified; follow the official docs for exact files):

ServiceRoleNotes
n8n (main)Editor, webhooks, schedulingPinned version, environment variables, persistent volume
PostgreSQLWorkflows, credentials, execution dataPrivate network only, daily dumps
Reverse proxy (Caddy or Traefik)HTTPS and routingAutomatic certificates for your subdomain
Redis and workers (optional)Queue mode for scalingOnly when volume requires it
Backup jobDatabase dumps and workflow exportsCopies to off-server storage

How do you monitor a self-hosted instance?

—An uptime monitor that checks the n8n URL every few minutes and alerts by email, SMS or Telegram.
—An error workflow in n8n that notifies you whenever any workflow fails.
—Server metrics: CPU, memory and disk usage, with alerts before the disk fills.
—Execution data pruning settings, so old execution logs do not grow the database forever.
—A monthly check of n8n release notes and security advisories.

Disk space is the most common cause of outages we see on small self-hosted instances: execution logs and binary data accumulate silently. Configure pruning from day one.

Can you run n8n on shared hosting or a cPanel account?

Generally not well. n8n needs a long-running Node.js process, persistent storage and often Docker, which typical shared hosting does not provide reliably. A small VPS or a managed container platform is the practical minimum. Some hosting panels now offer Node.js app hosting that can run n8n, but check memory limits and process limits carefully before relying on it for business workflows.

What about agencies hosting n8n for several clients?

Agencies often run one instance per client for isolation of data and credentials, or use n8n’s enterprise features for multi-team setups. Keep clients’ credentials separate, document who owns each server, and include hosting and maintenance in the monthly care plan. Check the license terms if hosting for clients is part of what you sell.

Our No-Code Agentic AI Development batches run live online, so the same class reaches learners and business owners in metros such as Bengaluru, Pune, Kolkata, Mumbai and Delhi NCR, growing cities such as Jaipur, Kanpur, Madurai, Raipur and Dehradun, and smaller industrial towns such as Panipat, Firozabad, Karur, Durgapur and Dibrugarh, at the same fee. Each city page explains how local businesses use n8n deployment, for example in Jaipur, Panipat, Madurai.

Learn this live: No-Code Agentic AI Development

Deploy, secure and monitor your own n8n instance and ship AI automations to production. 40 live hours, ₹34,999 paid in full or ₹40,000 as No-Cost EMI of ₹20,000 × 2.

LONG-TERM PROGRAM · LIVE ONLINE
No-Code Agentic AI Development

Ship AI agents that do real work — without writing production code.

₹34,999 paid in full · EMI ₹20,000 × 240 hoursLive, mentor-ledCertificate on completion

Frequently asked questions

Is self-hosted n8n free?+

Self-hosting n8n is free for internal business use under its Sustainable Use License. You pay for the server, any model APIs and your own maintenance time. Check the license if you plan to offer n8n to others as a service.

What server size do I need for n8n?+

For a small business with a few dozen workflows, about 2 vCPU and 4 GB RAM is usually enough. AI and file-heavy workloads benefit from 4 vCPU and 8 GB RAM; high volume may need queue mode with workers.

Should I use SQLite or PostgreSQL with n8n?+

PostgreSQL is recommended for production self-hosting because it is more robust for concurrent executions, backups and growth. SQLite is fine for testing.

How do I get HTTPS for n8n?+

Put n8n behind a reverse proxy such as Caddy, Traefik or Nginx that obtains free certificates automatically, point a subdomain to the server and set the host, protocol and webhook URL variables.

Can I host n8n in India?+

Yes. Many providers offer VPS servers in Indian data centres such as Mumbai, Bengaluru, Chennai and Delhi NCR, which helps latency and data residency preferences.

Where can I learn to deploy n8n?+

Careers Ninza No-Code Agentic AI Development covers deployment, measurement and rollout, including self-hosting. 40 live hours, ₹34,999 paid in full or ₹40,000 as No-Cost EMI of ₹20,000 × 2.

Related reading

AI & AUTOMATION Rolling Out Claude Across an Indian Company: Pilots, Governance, Training and ROI Buying licences is the easy part of an AI rollout. This guide covers how Indian companies should pilot Claude, set governance and data rules, train people by role, build shared Skills and connectors, control cost and measure real value. 6 min read AI & AUTOMATION AI Automation for HR and Recruitment: Screening, Onboarding and Employee Questions HR teams spend hours on repetitive tasks: sorting CVs, scheduling interviews, onboarding paperwork and answering the same policy questions. This guide shows practical AI automations for Indian HR teams, with fairness and privacy safeguards. 6 min read AI & AUTOMATION Claude for Small Business Owners in India: 20 Practical Uses That Save Time and Money Owners of Indian MSMEs wear every hat: sales, accounts, HR, marketing and operations. This guide lists 20 practical ways Claude helps, from quotations and GST-ready summaries to job descriptions and customer replies, with safety rules and a plan to start. 6 min read

We teach this, live

Every article here comes from something we teach. Sit in on a free masterclass and judge the mentors yourself.