How to Install Homepage on a Docker VPS: One Dashboard for Your Whole Self-Hosted Stack

Homepage dashboard on a Docker VPS

When opening your own services starts to feel like guesswork

Services on a single VPS tend to accumulate quietly. One panel becomes two, then a file manager, a media server, a download client, and an uptime monitor join in. Each one lives at its own address and port, and before long the simple act of opening a service turns into a memory test: which port was that one on, did the address change, and where did you leave the admin link. Browser bookmarks help a little, but a bookmark cannot tell you whether a service is actually running or died overnight.

Homepage, the dashboard from the gethomepage project, fixes this with deliberate simplicity. It puts everything on one page: links grouped the way you like them, a running-or-stopped indicator for Docker containers, and small live figures from services that support widgets, such as a download queue or current viewers. There is no database and no admin panel to click through. The whole configuration is a set of YAML files in one directory that you can back up, copy to another server, or keep in Git. Once it is set up, opening your VPS feels like walking through one front door instead of rummaging through drawers.

This guide installs Homepage with Docker Compose on a VPS, from the first container to services that appear on their own through Docker labels.

Prerequisites

You need a VPS with Docker and the Docker Compose plugin already running. Confirm both with:

docker --version
docker compose version

Both commands should print version numbers without errors. If Docker is not installed yet, install it first and make sure your user can run docker ps without repeated sudo, or run the commands in this guide with sudo as your server requires.

Decide how you will open the dashboard. On the VPS itself, localhost:3000 is enough. From your home or office network, prepare a domain such as dashboard.example.com and point it at the VPS. One point matters from the start: Homepage ships no login layer of its own.

Finally, jot down the services you want on the dashboard: a name, an internal address with port, and the Docker container name where one exists. A short list up front makes the YAML steps far quicker than inventing groups while you type.

Step 1: Prepare the directories and the Compose file

Create a project directory and a configuration directory inside it. The configuration directory is what gets mounted to /app/config in the container:

mkdir -p ~/homepage/config
cd ~/homepage

Check your user and group IDs, so files written by the container stay owned by the right user:

id -u
id -g

On most systems both commands return 1000 for the first user. Now create docker-compose.yml, replacing 1000 if your IDs differ and replacing the hosts in HOMEPAGE_ALLOWED_HOSTS with the addresses you will actually use to open the dashboard:

services:
  homepage:
    image: ghcr.io/gethomepage/homepage:latest
    container_name: homepage
    environment:
      HOMEPAGE_ALLOWED_HOSTS: localhost:3000,127.0.0.1:3000,dashboard.example.com
      PUID: 1000
      PGID: 1000
    ports:
      - 127.0.0.1:3000:3000
    volumes:
      - ./config:/app/config
    restart: unless-stopped

Three details in this file deserve attention. First, HOMEPAGE_ALLOWED_HOSTS is required and guards against DNS rebinding attacks: Homepage rejects requests from hosts not on the list. List every host you use, separated by commas with no spaces, and include the port when it is non-standard, such as localhost:3000. If you open the dashboard by domain, that domain must be listed; if by IP address, list the IP with its port. Second, the port binds to 127.0.0.1, so port 3000 is not directly visible from outside the server; public access will go through a reverse proxy later. Third, the ./config:/app/config volume is Homepage's entire memory. Back up that directory and you can rebuild the dashboard on another server without redoing the configuration.

Start the container:

docker compose up -d

Then check its state:

docker compose ps
docker logs homepage --tail 50

You should see a running container and logs without repeated errors. Open http://localhost:3000 on the server, or tunnel from a remote machine with something like ssh -L 3000:localhost:3000 user@VPS-IP and then open http://localhost:3000 in your browser. The first page will show Homepage's default examples. That generic look is expected: your own configuration comes in the next steps.

Step 2: Learn the five configuration files

List the configuration directory:

ls -la ~/homepage/config

Homepage reads its configuration from YAML files in this directory. The five you will touch most are:

  • services.yaml — the services shown as cards, grouped as you choose.
  • bookmarks.yaml — plain web links that need no status or widget.
  • widgets.yaml — information widgets across the top of the page, such as a logo, date, and search.
  • settings.yaml — page title, theme, and group layout.
  • docker.yaml — Docker connection definitions, used for container status and automatic discovery.

Homepage watches these files, so editing YAML and saving is usually enough to update the page without rebuilding the container.

Step 3: Write your first services in services.yaml

Open ~/homepage/config/services.yaml and write the first group. The official structure is simple: groups are top-level list entries, and each group holds services whose main property is href. Adjust the example addresses to your own services:

- Media:
    - Jellyfin:
        icon: jellyfin.png
        href: http://192.168.1.10:8096
        description: Family media server
    - Immich:
        icon: immich.png
        href: http://192.168.1.10:2283
        description: Photo and video gallery
- Tools:
    - Portainer:
        icon: portainer.png
        href: http://192.168.1.10:9000
        description: Manage Docker containers

Save, reload the dashboard, and both groups will appear with their cards.

Services can also carry a short description and a siteMonitor, a URL whose availability is checked over HTTP. For example:

- Tools:
    - Portainer:
        icon: portainer.png
        href: http://192.168.1.10:9000
        description: Manage Docker containers
        siteMonitor: http://192.168.1.10:9000

The status indicator on the card will reflect that check.

Step 4: Move ordinary links to bookmarks.yaml

Not every link deserves a service card. Project documentation, a VPS provider panel, or a site you visit often has no container status and needs no widget. Those links fit better in bookmarks.yaml, which uses a similar group structure:

- Reference:
    - Docker Documentation:
        icon: docker.png
        href: https://docs.docker.com/
    - VPS Provider Panel:
        icon: mdi-server
        href: https://panel.example-provider.com/

One rule from the documentation is worth remembering: service groups and bookmark groups should use different names. Reusing a name across both files can produce surprising behavior, such as a bookmark group disappearing. If Media is already a group in services.yaml, do not use Media again in bookmarks.yaml; pick something distinct, like Media Reference.

After saving, the result should be compact link rows below the service cards, not large cards eating up space.

Step 5: Add information widgets in widgets.yaml

Information widgets sit at the top of the page and are defined in widgets.yaml, in the order you write them. Start with the simplest, a clickable logo:

logo:
  href: https://example.com

Other information widgets follow the same pattern: each has a name and its own documented options. Date and time, a search bar, weather, and system statistics are among the available widgets, and each widget's options are listed on its documentation page. Do not guess option names from another widget, because one wrong key can leave a widget blank with no clear error on the page.

The practical rule is one widget at a time: add it, save, reload, and confirm it renders before adding the next.

Homepage dashboard diagram

Step 6: Connect Docker through a socket proxy, not the raw socket

So far the dashboard is a tidy set of links. Homepage becomes genuinely useful when a service card knows whether its container is running, and how much CPU and memory it uses.

Add the proxy service to your docker-compose.yml, below the homepage service, then recreate the stack:

services:
  dockerproxy:
    image: ghcr.io/tecnativa/docker-socket-proxy:latest
    container_name: dockerproxy
    environment:
      - CONTAINERS=1
      - SERVICES=1
      - TASKS=1
      - POST=0
    ports:
      - 127.0.0.1:2375:2375
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock:ro
    restart: unless-stopped
  homepage:
    image: ghcr.io/gethomepage/homepage:latest
    container_name: homepage
    environment:
      HOMEPAGE_ALLOWED_HOSTS: localhost:3000,127.0.0.1:3000,dashboard.example.com
      PUID: 1000
      PGID: 1000
    ports:
      - 127.0.0.1:3000:3000
    volumes:
      - ./config:/app/config
    restart: unless-stopped

The POST=0 setting is the security key here: the proxy refuses write operations, making this path effectively read-only.

docker compose up -d

Now define the Docker connection in ~/homepage/config/docker.yaml, referring to the proxy by its Compose service name on the same network:

my-docker:
  host: dockerproxy
  port: 2375

The name my-docker is yours to choose, but it is the name services.yaml will reference. The documented alternative is mounting the socket directly with /var/run/docker.sock:/var/run/docker.sock and a socket: /var/run/docker.sock entry in docker.yaml. The official documentation records one important condition for that route: Homepage must run as root. That alone makes the direct socket a poor default here. The Docker socket is equivalent to root access on the host, so handing it to a web-reachable container is not a shortcut worth taking to save one small proxy service.

Step 7: Link service cards to their containers

With the Docker connection defined, add server and container to a service in services.yaml. The server name must match docker.yaml exactly, and the container name must match the container_name or the name shown by docker ps:

- Media:
    - Jellyfin:
        icon: jellyfin.png
        href: http://192.168.1.10:8096
        description: Family media server
        server: my-docker
        container: jellyfin
        showStats: true

Save, reload the page, and the card's status indicator will show the container state. Clicking the status label expands container statistics: CPU, memory, and network activity. The showStats: true option controls whether those statistics appear, and it can be set per service if you only want detail on certain cards.

Step 8: Let new services appear on their own with Docker labels

Writing every service by hand is controlled, but it gets tedious. Homepage supports automatic discovery: a container carrying labels with the homepage. prefix appears on the dashboard by itself once the docker.yaml connection is correct, with no entry needed in services.yaml. Here is an example label set on another service's Compose file:

services:
  jellyfin:
    image: jellyfin/jellyfin:latest
    container_name: jellyfin
    ports:
      - 8096:8096
    restart: unless-stopped
    labels:
      - homepage.group=Media
      - homepage.name=Jellyfin
      - homepage.icon=jellyfin.png
      - homepage.href=http://192.168.1.10:8096
      - homepage.description=Family media server

After recreating that container with docker compose up -d, the Jellyfin card appears under Media.

Step 9: Tidy the title and layout in settings.yaml

Open ~/homepage/config/settings.yaml and set the page title and group layout. This example titles the page and shows the Media group as a four-column row:

title: Server Dashboard
layout:
  Media:
    style: row
    columns: 4

Groups can use a column or row layout, and their order follows the order of the layout block.

Step 10: Secure access with a reverse proxy or VPN

This final step decides whether the dashboard may be opened from the internet. Since Homepage has no login of its own, do not leave port 3000 open; use a VPN, or a reverse proxy with TLS and authentication in front of Homepage.

A skeleton Nginx setup for this pattern, assuming basic authentication is managed in a separate password file, looks like this:

server {
    listen 443 ssl;
    server_name dashboard.example.com;

    auth_basic "Private dashboard";
    auth_basic_user_file /etc/nginx/.htpasswd;

    location / {
        proxy_pass http://127.0.0.1:3000;
        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;
    }
}

Once the proxy is live, verify three things: the page loads over HTTPS, the browser asks for credentials before showing the dashboard, and HOMEPAGE_ALLOWED_HOSTS includes the domain. If any of the three fails, fix it before sharing the dashboard address with anyone. A dashboard listing your internal services is a map of your network; opening it without authentication is like pinning that map to the front door.

For updates, pull the latest image and recreate the container:

docker compose pull
docker compose up -d
docker compose ps

Because all configuration lives in the config directory, an update does not erase your dashboard.

Homepage versus browser bookmarks and container panels

AspectBrowser bookmarksContainer panelHomepage
One page for all servicesNo, scattered across the bookmark barNo, Docker containers onlyYes, services and links in groups
Running or stopped statusUnknownYes, for containersYes, through the Docker connection
CPU and memory statisticsNoneYesYes, by clicking a card's status
Service data, such as queuesNoneNoneYes, through service widgets
ConfigurationBrowser clicks, hard to back upPanel clicksYAML files, easy to back up and keep in Git
Built-in loginEach browser login separatelyDepends on the panelNone, requires a reverse proxy or VPN
Best forPersonal use on one deviceManaging containersA daily front door for the whole stack

The last row matters. Homepage does not replace a container management panel like Portainer, and it does not replace an uptime monitor.

Common mistakes and how to fix them

SymptomMost likely causeFix
Page refuses to load with a host validation errorThe host in use is missing from HOMEPAGE_ALLOWED_HOSTSAdd the host with its port, comma-separated with no spaces, then recreate the container with docker compose up -d
Host change has no effect after a restartA restart does not re-read environment variablesRecreate the container, not just docker compose restart
Blank page after editing YAMLYAML syntax or indentation errorCheck docker logs homepage, fix the indentation, save again
Service does not appearWrong group name or indentation in services.yamlMatch the example structure, check spaces, never tabs
Card shows no container statusdocker.yaml missing or server name mismatchMatch the name in docker.yaml and server in services.yaml, confirm the proxy is running
Labels produce no automatic cardDocker connection wrong or container not recreatedVerify docker.yaml, recreate the labeled container, check the logs
Statistics empty while status showsshowStats off or proxy restricting endpointsEnable showStats: true, confirm CONTAINERS=1 on the proxy
Config files owned by root and hard to editPUID or PGID mismatch with the host userMatch PUID and PGID to id -u and id -g, fix directory ownership, recreate the container
Dashboard open to anyonePort published without a reverse proxy or VPNRestore 127.0.0.1:3000:3000, add proxy authentication
Widget shows no dataWidget URL unreachable from the container networkUse an internal address the container can reach, check that widget's documentation

The pattern running through this table is familiar: most Homepage problems are not application failures but three things, an unlisted host, a YAML indentation slip, or a Docker connection whose names do not match. Checking those three in that order resolves most reports of a page that will not render.

Final checklist

  • The homepage container runs from ghcr.io/gethomepage/homepage:latest and opens at http://localhost:3000.
  • HOMEPAGE_ALLOWED_HOSTS lists every host and port you use, and the container was recreated after any environment change.
  • The port stays bound to 127.0.0.1 until a reverse proxy or VPN is ready.
  • Key services are written in services.yaml and appear in the correct groups.
  • Ordinary links moved to bookmarks.yaml under distinct group names.
  • Information widgets in widgets.yaml render across the top of the page.
  • The Docker connection through the socket proxy is defined in docker.yaml with POST=0.
  • Container-linked cards show status, and statistics open from the status label.
  • At least one service appears automatically through a Docker label.
  • Title and layout in settings.yaml match what you want.
  • Internet access passes through HTTPS and proxy authentication or a VPN.
  • The config directory is included in your regular backups.

Which service did you put on your Homepage dashboard first, and did label-based discovery change how you write your Compose files? Share it in the comments, so other readers can compare their dashboard layouts with yours.

Read also: Companion article in this batch and "How to Run Docker Rootless on a VPS: A Daemon Without Root Access" for hardening the Docker host itself.

Diskusi

Ada pertanyaan atau pengalaman yang ingin dibagikan?

0komentar

Komentar ditinjau sebelum ditampilkan. Mari berdiskusi dengan sopan dan sesuai topik.