# Dokploy: A Self-Hosted PaaS for Your Own VPS

> Run Dokploy as a Heroku-style, self-hosted PaaS on a single VPS. Here is what runs under the hood, and how app deploys, databases, Traefik routing, and backups fit together.

URL: https://www.matthewswong.com/en/blog/dokploy-self-hosted-paas-vps/

- Author: Matthews Wong (https://www.matthewswong.com/en/about/)
- Published: 2026-07-01
- Updated: 2026-07-01
- Category: DevOps

Dokploy is an open-source Platform as a Service that you install on a server you own. It bills itself as an alternative to Heroku, Vercel, and Netlify, but instead of paying per app on someone else's cloud, you point it at a single VPS and get a Heroku-style deploy experience on hardware you fully control.

In this walkthrough I cover what Dokploy actually is, the pieces it runs under the hood, how application and database deploys work, and how Traefik routing plus scheduled backups fit together. The goal is a clear mental model before you type the install command, so that when something needs debugging you understand which layer to look at rather than treating the whole thing as a black box.

## What Dokploy actually is

At its core Dokploy is a web dashboard that sits on top of Docker. You connect a Git repository or point it at a Docker image, and Dokploy handles building, running, and exposing the result. Everything you would normally wire up by hand on a raw VPS is presented as buttons and forms, while the underlying primitives stay standard Docker, so nothing is locked behind a proprietary format. Under the surface every app becomes a Docker Swarm service, which means the same tooling that runs a hobby blog can later scale to a small cluster without changing how you work day to day.

- Application deploys from a Git repo, a Dockerfile, or a plain Docker image, with automatic rebuilds on every push.
- Managed databases including PostgreSQL, MySQL, MariaDB, MongoDB, and Redis, each running as its own container.
- Docker Compose support, so a multi-service stack deploys and updates as a single unit.
- One-click open-source templates such as Plausible, PocketBase, and Cal.com for common self-hosted tools.

> Give Dokploy a dedicated VPS. The docs recommend at least 2 GB of RAM and 30 GB of disk, and the installer takes over Docker, Swarm, and ports 80, 443, and 3000. Running it next to unrelated services on the same box invites port conflicts and noisy-neighbour surprises.

## Getting Dokploy onto a fresh VPS

Installation is a single shell command run as root on a clean Ubuntu or Debian server. The script detects an existing Docker install rather than clobbering it, and it has been tested across Ubuntu 18.04 through 24.04, Debian 10 to 12, and a few RHEL-family distributions. You can safely re-run the same command later to upgrade Dokploy itself, and it keeps your existing projects and data intact. Here is what actually happens the first time you run it:

Once the dashboard loads on port 3000, the very first thing you do is create the admin account. After that, lock the panel down behind a real domain with HTTPS instead of leaving the raw IP and port exposed to the internet.

## What runs under the hood

Dokploy is not a rewrite of the deployment stack; it is glue around battle-tested tools. Understanding the layers helps you debug when something misbehaves, because you can always drop down to plain Docker or Traefik commands underneath the dashboard. This layered design is also why moving away is painless: your apps are ordinary containers and your data lives in named Docker volumes, both of which you can copy to any other host.

| Layer | What it does for you | Underlying technology |
| --- | --- | --- |
| Orchestration | Schedules containers, restarts crashed ones, and rolls out new versions | Docker Swarm |
| Routing and TLS | Maps your domains to the right container and issues HTTPS certificates | Traefik with Let's Encrypt |
| Builds | Turns a Git repo into a runnable image, no Dockerfile required | Nixpacks or Buildpacks |
| Backups | Runs scheduled database dumps and ships them off the server | Native dump tools streamed to S3 |

## Deploying your first application

A typical deploy is a handful of clicks in the dashboard. The flow mirrors what Heroku made popular, minus the monthly bill:

1. Create a project, then add an application inside it and choose a Git provider or a Docker image as the source.
2. Set environment variables and, if needed, a build command; Dokploy autodetects most Node, Python, Go, and PHP stacks through Nixpacks.
3. Attach a domain under the Domains tab and toggle HTTPS, which tells Traefik to request a certificate automatically.
4. Hit Deploy and watch the live build logs; on success the app is reachable at your domain within seconds.

> A single VPS is a single point of failure. If that box dies, every app on it goes down together, and Dokploy itself is unavailable until you restore. Treat off-server backups as mandatory, never expose port 3000 to the open internet, and if uptime matters, plan for Swarm across multiple nodes before you depend on it.

## Databases and automated backups

Databases are first-class citizens. You create one from the dashboard, get connection credentials, and reference it from your apps over the internal Docker network. The part people forget is backups, so Dokploy makes them a scheduled job that streams dumps to any S3-compatible bucket. It is worth periodically restoring one of those dumps into a throwaway database, because a backup you have never tested is only a hope, not a recovery plan:

## Routing, domains, and TLS with Traefik

Every domain you attach becomes a Traefik router rule. Because Traefik watches Docker labels, adding or removing an app updates routing live with no manual reload. A few things worth knowing:

- Certificates are requested and renewed automatically through Let's Encrypt, so you rarely touch TLS by hand.
- You can edit the raw Traefik configuration from the dashboard when you need custom middleware, redirects, or headers.
- Multiple apps share ports 80 and 443, with Traefik routing by hostname, so you are not juggling one port per service.

The template catalogue is an underrated time-saver. Deploying something like Plausible analytics or PocketBase is a single click that provisions the container, database, and domain wiring for you, which is a genuinely faster path than assembling a Compose file by hand.

## Is Dokploy right for your VPS?

Dokploy shines when you want the Heroku developer experience without recurring platform fees and you are comfortable owning a Linux server. It is a strong fit if you can answer yes to these:

- You have a spare VPS with at least 2 GB of RAM that you can dedicate to it.
- You want push-to-deploy, managed databases, and automatic HTTPS without stitching the tooling together yourself.
- You accept the single-server trade-off for hobby and small production workloads, or you plan to scale to multiple Swarm nodes later.

Dokploy hits a sweet spot for developers who have outgrown manual SSH deploys but do not want a cloud provider's bill. It gives you a real PaaS on your own VPS, keeps the internals as plain Docker so you never feel trapped, and gets you from a blank server to a running app in well under an hour. Because everything underneath is standard Docker, Swarm, and Traefik, the skills you build here transfer directly to any container platform you meet later. Start on a throwaway server, deploy one small app end to end, and you will quickly know whether it belongs in your stack.

## Sources and further reading

- Dokploy on GitHub — source code and self-hosting documentation
- Dokploy docs — scheduling database backups to S3
- Docker — overview on Wikipedia

## Source links

- https://github.com/dokploy/dokploy
- https://docs.dokploy.com/docs/core/databases/backups
- https://en.wikipedia.org/wiki/Docker_(software)

## FAQ

### What is Dokploy and how is it different from Heroku?

Dokploy is an open-source Platform as a Service you install on your own server. It gives you a Heroku-style push-to-deploy workflow, managed databases, and automatic HTTPS, but it runs on a VPS you control instead of a paid cloud platform. There are no per-app fees, and the internals stay standard Docker so you are never locked in.

### What does Dokploy use under the hood?

Dokploy is glue around proven tools rather than a new runtime. It uses Docker Swarm for orchestration, Traefik with Let's Encrypt for routing and HTTPS, and Nixpacks or Buildpacks to turn a Git repo into an image without a Dockerfile. Because these layers are standard, you can always drop down to plain Docker or Traefik commands to debug.

### What are the minimum server requirements to run Dokploy?

The documentation recommends a VPS with at least 2 GB of RAM and 30 GB of disk space. It has been tested on Ubuntu 18.04 through 24.04, Debian 10 to 12, and several RHEL-family distributions. Installation is a single curl command run as root, and the script installs Docker and initialises Swarm for you.

### Can Dokploy back up my databases automatically?

Yes. Dokploy can schedule recurring database backups using cron syntax and stream the dumps to any S3-compatible bucket. It shells out to the native dump tool for each engine, such as pg_dump for PostgreSQL or mysqldump for MySQL. Because a single VPS is a single point of failure, keeping these off-server backups is strongly recommended.

### Is Dokploy safe to run in production on one VPS?

It is fine for hobby projects and small production workloads, with two caveats. A single VPS is a single point of failure, so if the server dies every app goes down until you restore from backup. For higher uptime you should scale Dokploy across multiple Docker Swarm nodes and never expose the dashboard port directly to the internet.

---

- HTML version: https://www.matthewswong.com/en/blog/dokploy-self-hosted-paas-vps/
- Bahasa Indonesia: https://www.matthewswong.com/id/blog/dokploy-self-hosted-paas-vps/
- Site index for agents: https://www.matthewswong.com/llms.txt
- Sitemap: https://www.matthewswong.com/sitemap.xml
- API description (OpenAPI): https://www.matthewswong.com/openapi.json
