Install Coolify self-hosted PaaS on VPS

Install Coolify on VPS (Self-hosted PaaS)

June 2026 · 8 min read

Coolify is an open-source self-hosted PaaS that gives you the experience of Heroku, Vercel, or Netlify running on your own VPS — deploy apps from Git automatically, get free SSL from Let's Encrypt, manage databases and Redis via dashboard, and support Docker Compose without paying expensive monthly platform fees or being locked in by a vendor. This guide walks you through installation and deploying your first app step by step.

System Requirements

Install Coolify

# Official installation script (installs Docker if not present)
curl -fsSL https://cdn.coollabs.io/coolify/install.sh | sudo bash

# When done, open the dashboard for the first time at
# http://YOUR_VPS_IP:8000
# Create an admin account and configure your dashboard domain
Note: After setting your dashboard domain (e.g., coolify.yourdomain.com), Coolify will request an SSL certificate automatically — make sure to open ports 80, 443, and 8000 on your firewall and point an A record to your VPS first.

Connect Git and Deploy Your First App

# In the dashboard:
# 1. Sources > Connect GitHub/GitLab (via GitHub App or deploy key)
# 2. + New Resource > select repository
# 3. Coolify auto-detects build pack:
#    - Nixpacks (auto-detect Node/Python/PHP/Go)
#    - Dockerfile
#    - Docker Compose
# 4. Set your app domain, e.g., app.yourdomain.com
# 5. Click Deploy — Coolify will build + run + request SSL

Each time you push to the configured branch, Coolify automatically rebuilds and redeploys via webhook, giving you built-in CI/CD without setting up a separate pipeline.

Add Database and Environment Variables

# Add a database via dashboard:
# + New Resource > Databases > PostgreSQL / MySQL / Redis / MongoDB
# Coolify creates the container and connection string for you

# Set app environment variables:
# Go to Application > Environment Variables
# Enter DATABASE_URL, SECRET_KEY, etc.
# Click Redeploy to apply new environment variables

Configure Automatic Database Backups

Coolify includes built-in scheduled database backups to S3/local storage — enable it for all production databases:

# Database > Backups
# - Set schedule (cron, e.g., 0 3 * * * = 3 AM every night)
# - Choose destination: Local or S3-compatible
# - Set retention (how many backups to keep)

Verify Coolify is Working Correctly

Confirm that the Coolify core, proxy, and deployed apps are running and SSL is issued:

# 1. Coolify containers running
docker ps | grep -E 'coolify|traefik'

# 2. Proxy (Traefik) listening on ports 80/443
sudo ss -tlnp | grep -E ':80|:443'

# 3. Test deployed app responds over HTTPS
curl -I https://app.yourdomain.com

# 4. View deployment log for the app (in dashboard or)
docker logs <app-container-name> --tail 50
Tip: If the app deploys successfully but returns 502 when you try to open it, it's usually a "port mismatch" — the port your app listens on doesn't match what Coolify expects. Check Ports Exposes in the app settings to match your app's actual listening port (Node apps typically use port 3000).

Common Issues & Troubleshooting

Cannot access dashboard after install (port 8000)

Firewall blocking or service hasn't finished starting. Check:

sudo ufw allow 8000,80,443/tcp
docker ps | grep coolify     # Should see running container
docker logs coolify --tail 50

Build fails with "out of memory"

Building apps (especially Node/Next.js) consumes high RAM. A 2 GB VPS may not be enough. Add temporary swap or upgrade RAM:

sudo fallocate -l 2G /swapfile && sudo chmod 600 /swapfile
sudo mkswap /swapfile && sudo swapon /swapfile

SSL doesn't issue (still showing HTTP)

Your domain isn't pointing to the VPS or port 80 is blocked, preventing Let's Encrypt validation. Check: dig +short app.yourdomain.com must return your VPS IP.

Webhook doesn't trigger auto-deploy

Verify GitHub App/deploy key is properly connected and Coolify's webhook URL is reachable from outside (requires domain + SSL, not bare IP). Check delivery logs in GitHub > Settings > Webhooks.


Frequently Asked Questions

Is Coolify really free?

The self-hosted version is 100% free and open source — you only pay for the VPS it runs on. There's a Cloud version where Coolify hosts it for you, which costs money for those who don't want to manage servers. Core features are the same.

Who is it suitable for?

Coolify is ideal for developers or small teams who want a Heroku/Vercel-like workflow but need to control costs and keep their data. Run multiple projects on one VPS. Perfect for side projects, staging, and small-to-medium production apps.

Is it hard to migrate from Heroku/Vercel to Coolify?

Not difficult if your app has a standard Dockerfile or build pack. Usually just connect the repo, set your existing environment variables, and migrate the database. The main work is pointing DNS and setting up backups before switching traffic over.