English
Get started
← All templates

Deploy Umami on Pethost in one click

Web analytics for your sites, without cookies

What happens

  1. You sign in to Pethost or make an account, with a passkey, GitHub or Google.
  2. No machine yet? You pick a plan, and we prepare one for you. The link waits in your browser until it is ready.
  3. New project opens at the app, and you click Create project.
  4. In a minute or two the app is live at its own address with HTTPS. Its secrets are made for it at random, and its data is in the nightly backup.
  5. It is a project like any other: its compose.yaml, its .env, its logs and a terminal are in the panel, and your agent can change it, roll it back or restore it.

First steps

Sign in as admin with the password umami and change it at once in your profile. Then add your website and put its tracking script on your pages.

What it runs

The template is this compose.yaml and the variables it writes into the project’s .env. Pethost runs the file as it is written.

services:
  umami:
    image: ghcr.io/umami-software/umami:3
    restart: unless-stopped
    init: true
    environment:
      DATABASE_URL: postgresql://umami:${POSTGRES_PASSWORD}@db:5432/umami
      APP_SECRET: ${APP_SECRET}
      TWO_FACTOR_ENCRYPTION_KEY: ${TWO_FACTOR_ENCRYPTION_KEY}
    depends_on:
      db:
        condition: service_healthy
    healthcheck:
      test: ["CMD", "curl", "-fsS", "http://localhost:3000/api/heartbeat"]
      interval: 5s
      timeout: 5s
      retries: 5
      start_period: 60s

  db:
    image: postgres:15-alpine
    restart: unless-stopped
    environment:
      POSTGRES_DB: umami
      POSTGRES_USER: umami
      POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
    volumes:
      - db-data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -h 127.0.0.1 -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
      interval: 5s
      timeout: 5s
      retries: 5
      start_period: 30s

volumes:
  db-data: