Introduction
Coolify is a free and open-source tool that lets you easily host your own applications, databases, or services (like WordPress, Formbricks, and Grafana) without needing to manage servers yourself.
In this tutorial, you’ll learn how to install and set up Coolify on a Linux server.
We’ll use Debian 12 (Bookworm) in this tutorial, but these steps should also work on other Linux distributions supported by Coolify.
Prerequisites
This tutorial has been tested on a Hetzner Cloud Server but should work with any cloud server.
- A Cloud server (A fresh new server is recommended)
- An operating system supported by Coolify. You can find the list of supported operating systems in the Official Coolify Documentation
- Server architecture (either AMD64 or Arm64)
- Minimum specifications for Coolify: 2 vCPUs, 2GB RAM, and 30+ GB storage. These are the minimum requirements, so consider choosing a server with higher specifications based on your needs.
- Access to the root user
- An SSH key for authentication (recommended)
- If you need assistance setting up your new cloud server, you can follow the official Hetzner Cloud Server Setup Guide. Please skip any steps related to firewall configuration.
Example terminology
- Server
- Public IPv4:
203.0.113.1
- Public IPv4:
- Domains
- Domain:
example.com
- Subdomain:
sub.example.com
- Domain:
These examples are for tutorial purposes only, make sure to replace them with your own information.
Step 1 - Configure Your Server
First, connect to your server using SSH. If you’re not logged in as the root user, use the following command to access a root shell:
sudo -i
Note: The Coolify installation will fail if it's not run as root.
Step 1.1 - Update Your Server and Install Required Packages
Start by updating your server:
apt update && apt dist-upgrade -y
Then, install curl
, which is needed for the Coolify installation script:
apt install curl -y
Step 2 - Install Coolify
Run the installation script to install Coolify:
curl -fsSL https://cdn.coollabs.io/coolify/install.sh | bash
You can view the source code for the installation script in the Official Coolify Repository
Once the installation is complete, you’ll see the following message:
Congratulations, Your Coolify instance is ready to use.
Please visit http://203.0.113.1:8000 to get started.
Step 3 - Create a New Account on Coolify
Visit the link provided in the terminal after installing Coolify.
You’ll be prompted to create an account. Enter your details and set up your account.
Make sure to write down your account email and password, as you’ll need them to log in to Coolify in the future.
Step 4 - Configure the Domain for Coolify
After creating your account on Coolify, the first thing you need to do is set up a domain. Accessing Coolify via http://203.0.113.1:8000
(your server IP and port) is insecure because it uses HTTP
.
Once you connect a domain, Coolify will automatically generate and set up the proxy and SSL certificates.
Go to the DNS management page on your domain provider’s dashboard (like GoDaddy, Namecheap, etc.) and add two new A records as shown below:
@
allows Coolify to use the root of your domain.
*
allows Coolify to create and use any subdomain.
Note: If you don’t see the option for Auto
under TTL, select the lowest value available.
Next, go to the settings page in Coolify and add the domain you want to use for accessing Coolify in the "Instance Domain" field:
Finally, visit your instance domain in your browser. You should be able to access Coolify with HTTPS (it may take a minute or two for the website to be accessible for the first time).
Step 5 - Set Up the Firewall
On the Hetzner dashboard, navigate to the Firewalls section and create three new inbound rules as shown below:
Port
22
is for SSH connections.
Port
80
and443
are for the reverse proxy.
Once you enable the Firewall, you won’t be able to access Coolify via http://203.0.113.1:8000
(your server IP and port). You can only access Coolify through the instance domain you set up in the previous step (Step 4
).
All applications deployed on Coolify will use HTTPS
, as Coolify automatically handles the reverse proxy and SSL certificates.
Conclusion
We installed Coolify and set up a custom domain for it on our server. Additionally, we configured the firewall rules to restrict access to our server and Coolify from the server IP address, allowing access only via our custom domain.
I highly recommend checking out the Official Coolify Documentation for more information.
This tutorial will help you get started with Coolify, and you can learn more about setting up services, databases, and much more from their documentation.