> ## Content Index
> Fetch the complete content index at: https://blog.alphavps.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# How to Install Vaultwarden (Bitwarden Alternative) on a Linux VPS
- URL: https://blog.alphavps.com/how-to-install-vaultwarden-bitwarden-alternative-on-a-linux-vps/
- Published: 2026-03-09T10:36:20.000Z
- Updated: 2026-09-08T15:18:06.000Z
- Author: Karim Buzdar
- Tags: Tutorials, Security, Self-Hosting

Vaultwarden, a Rust-based alternative to Bitwarden's official server, is a fast and resource-efficient way to host your own password vault on a Linux VPS. Vaultwarden is a Rust alternative to Bitwarden’s official server. It allows you to host a password vault on your Linux VPS with minimal resources. Vaultwarden is a powerful password management tool that gives you complete control over your passwords while using minimal system resources.

This step-by-step tutorial will show you how to install Vaultwarden using Docker, Docker Compose, and Nginx on a Linux VPS, configure a reverse proxy via Nginx, and enable HTTPS. You'll also learn in just minutes how to secure your own password manager.

### What Is Vaultwarden?

Vaultwarden, an open-source implementation of Bitwarden compatible server written in Rust, is unofficial. It provides nearly all of Bitwarden's features at a fraction of the resource consumption.

**Key Features:**

- Fast and lightweight
- Private and self-hosted
- Bitwarden customers are fully supported
- Attachments, 2FA, password-sharing, and more
- Even on small VPS instances with 512MB RAM, it works great

## How to Install Vaultwarden (Bitwarden Alternative) on a Linux VPS

Vaultwarden can be installed on Linux VPSs to create a fast, secure, and privacy-friendly password management system. Docker, Nginx, and Let's Encrypt allow you to deploy a production-ready Vaultwarden in just minutes. It includes HTTPS, admin controls, and Bitwarden compatibility.

### Prerequisites

Make sure that you have the following:

- A Linux VPS (Ubuntu/Debian/CentOS)
- Root or sudo privileges
- Docker & Docker Compose installed
- Domain name for your VPS is optional, but recommended
- Open ports 80/443 in your firewall

### Step 1: Update Your System

Update your system packages first.

```bash
sudo apt update
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-decb0bf6-642c-4319-bff0-576b35eb6a07.png)

Ensure that your VPS has the latest security patches installed.

### Step 2: Install Docker and Docker Compose

Docker allows Vaultwarden to be easily deployed, managed, and updated with minimal configuration. Docker containers are compatible with Vaultwarden.

Install Docker:

```bash
sudo apt install docker.io -y
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-1215c316-10fe-492b-9f54-c22f7b9c0606.png)

Install Docker Compose:

```bash
sudo apt install docker-compose -y
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-24978908-77da-48e5-b117-bd937799318e.png)

Enable Docker:

```bash
sudo systemctl enable --now docker
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-919406a5-afb7-46e0-b269-59ae33227c30.png)

### Step 3: Create Vaultwarden Directory

This directory contains your Vaultwarden configuration files and data. Create a working directory:

```bash
sudo mkdir ~/vaultwarden
cd ~/vaultwarden
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-deb70e71-3e25-45fd-a1d0-b326d85a577d.png)

### Step 4: Create Docker Compose File

Create a docker-compose.yml file:

```bash
nano docker-compose.yml
```

Copy the configuration below:

```yaml
services:
  vaultwarden:
    image: vaultwarden/server:latest
    container_name: vaultwarden
    restart: always
    environment:
      WEBSOCKET_ENABLED: "true"
    volumes:
      - ./vw-data:/data
    ports:
      - "8080:80"
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-17be5bff-5c39-4526-9f0b-8f50e6e8cb28.png)

Save and exit. This will run Vaultwarden at port 8080 and store all encrypted data in the vwdata directory.

### Step 5: Start Vaultwarden

Launch the container:

```bash
sudo docker-compose up -d
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-873462a8-a267-466b-83a4-9f11c44b47b3.png)

### Step 6: Install Nginx (Reverse Proxy)

Install Nginx to enable HTTPS on port 443 and run Vaultwarden safely:

```bash
sudo apt install nginx -y
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-ae246109-9781-4ade-9ec7-81e8f5161f98.png)

Enable firewall rules in Ubuntu:

```bash
sudo ufw allow 'Nginx Full'
sudo ufw reload
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-d16200bb-9ba3-407b-b6d7-963413d8ca8f.png)

### Step 7: Configure Nginx Reverse Proxy

Create a new Nginx config file:

```bash
sudo nano /etc/nginx/sites-available/vaultwarden
```

Paste:

```nginx
server {
    listen 80;
    server_name yourdomain.com;
    location / {
        proxy_pass http://127.0.0.1:8080;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-7d74430c-81d3-44cb-9815-c413b472cff7.png)

Enable the configuration:

```bash
sudo ln -s /etc/nginx/sites-available/vaultwarden /etc/nginx/sites-enabled/
sudo systemctl restart nginx
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-26e9ce97-d8ec-4e2f-aeaf-6f4dafb8f763.png)

### Step 8: Secure Vaultwarden with HTTPS (SSL)

HTTPS is required because Vaultwarden deals with sensitive, encrypted password data.

Install Certbot:

```bash
sudo apt install certbot python3-certbot-nginx -y
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-b750e168-587c-452d-8ad8-999990a79a45.png)

Run SSL auto-install:

```bash
sudo certbot --nginx -d yourdomain.com
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-e73f99ae-657d-4a82-8351-90f94c5b479f.png)

Follow the instructions to get a Let's Encrypt certificate.

### Step 9: Enable Admin Panel (Optional)

Add the following environment variables to your docker compose.yml file:

```bash
ADMIN_TOKEN=YourStrongPasswordHere
```

Apply changes:

```bash
sudo docker-compose down
sudo docker-compose up -d
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-46204821-85e3-47cd-ae66-094ed71ee322.png)

### Step 10: Test Vaultwarden

Visit:

```text
https://yourdomain.com
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-a95960b3-2121-4865-9593-9777c2135eec.png)

Use your Bitwarden instance URL to log in using the Bitwarden browser extension or client.

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-cc123bdb-fb85-4e4c-b412-b86db2be925e.png)

Vaultwarden has now been fully installed and is ready to use!

### Step 11: Update Vaultwarden Easily

To update:

```bash
sudo docker-compose pull
sudo docker-compose up -d
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-258970f0-2e48-4b0a-9e9e-53b6af0ac4f3.png)

### Optional: Remove Vaultwarden

To uninstall completely:

```bash
sudo docker-compose down
sudo rm -rf ~/vaultwarden
```

![](https://blog.alphavps.com/content/images/2025/11/data-src-image-6b88d497-ea95-4058-87d9-d7a92d6066b1.png)

## Conclusion

Installing Vaultwarden onto a Linux VPS requires you to install Docker, Docker Compose, and a Vaultwarden deployment directory. You can then run the official Vaultwarden Container using a docker-compose.yml simple file. Finally, expose it via Nginx and HTTPS for secure access. Install Docker after updating your system. Create a Vaultwarden folder and configure Docker Compose so that the Vaultwarden Server with persistent storage is run. Install and configure Nginx to act as a reverse proxy pointing at Vaultwarden’s internal port. Secure your domain with Certbot and enable SSL. After everything is up and running, you will be able to access your Bitwarden-compatible password manager through your domain. You can also enable the admin panel if you want more control.

Deploy Valutwarden on our [**Cheap VPS**](https://alphavps.com/cheap-vps.html?ref=blog.alphavps.com) to host your own password valut. Contact us today and we would love to offer you affordable pricing for your project.