Web Analytics⭐ 27k+ GitHubLicense: MIT

How to Self-Host Umami Analytics with Docker Compose

Open-Source Alternative to: Google Analytics 4 & Fathom

Umami collects only essential web traffic metrics (pages, referrers, browsers, countries) without tracking personal identifiable information. It does not require cookie consent popups.

MINIMUM HARDWARE
1 GB RAM, 1 vCPU, 10 GB Disk
ESTIMATED SAVINGS
$180/year
OFFICIAL REPOSITORY
github.com/umami-software/umami ↗

Production Docker Compose File

Copy this tested configuration directly into your server's directory:

🐳 docker-compose.yml
version: '3.8'
services:
  umami:
    image: ghcr.io/umami-software/umami:postgresql-latest
    restart: always
    ports:
      - '3000:3000'
    environment:
      - DATABASE_URL=postgresql://umami:umami_pass@db:5432/umami
      - APP_SECRET=replace_with_a_random_hash
    depends_on:
      - db
  db:
    image: postgres:15-alpine
    environment:
      - POSTGRES_USER=umami
      - POSTGRES_PASSWORD=umami_pass
      - POSTGRES_DB=umami
    volumes:
      - umami_db:/var/lib/postgresql/data
volumes:
  umami_db:

Quick Deployment Steps

1. docker compose up -d 2. Open http://localhost:3000 (Default login: admin / umami) 3. Add your website domain and paste the script tag into your header.

Key Advantages & Trade-Offs

✓ Why Self-Host Umami Analytics?

  • Tiny tracking script (<3 KB) guarantees instant Core Web Vitals
  • 100% cookie-free and strictly GDPR/CCPA compliant out of the box
  • Multi-website support with shareable public dashboard links

⚠ What to Keep in Mind

  • Does not capture complex user cohort retention funnels
  • Requires self-managed PostgreSQL or MySQL database

More Self-Hosted Alternatives

Knowledge & Workspace
AppFlowy
Replaces Notion ($10/seat/mo)
Project Management
Plane
Replaces Jira ($8.50/seat/mo) & Linear
No-Code Database
NocoDB
Replaces Airtable ($20/seat/mo)