umami
Product
DocsDevelopersPricing
16.8kLog inSign up
General
About
FAQ
Useful links
Getting started
Getting started
Install
Login
Add a website
Collect data
Basics
Add a user
Enable share URL
Track events
Teams
Updates
Languages
Advanced
Tracker configuration
Tracker functions
Environment variables
Reference
API
Authentication
Users
Teams
Websites
Website stats
Sending stats
Event Data
API Client
Cloud
Overview
API key
Import data
Guides
Migrating v1 to v2
Hosting
Running on DigitalOcean
Running on Vercel
Running on Neon Postgres
Running on Netlify
Running on Heroku
Running on Railway
Running on Supabase
Running on PlanetScale
Running on Qovery
Running on CapRover
Running on Koyeb
Running on Forge
Running on Fly.io
umami
Product
FeaturesPricing
Resources
DocsGuidesAPI ReferenceRelease Notes
Community
Get InvolvedGitHubDiscordTwitter
Company
AboutContactPrivacyTerms
© 2023 Umami Software, Inc.

Installation

Installing from source

Requirements

  • A server with Node.js version 16.13 or newer.
  • A database. Umami supports MySQL (minimum v5.7) and PostgreSQL (minimum v12.14) databases.

Install Yarn

npm install -g yarn

Get the source code and install packages

git clone https://github.com/umami-software/umami.git
cd umami
yarn install

Configure Umami

Create an .env file with the following

DATABASE_URL={connection url}

The connection url is in the following format:

DATABASE_URL=postgresql://username:mypassword@localhost:5432/mydb

DATABASE_URL=mysql://username:mypassword@localhost:3306/mydb

Build the application

yarn build

The first time the build is run, it will create all the required database tables in your database. It will also create a login account with username admin and password umami.

Start the application

yarn start

By default this will launch the application on http://localhost:3000. You will need to either proxy requests from your web server or change the port to serve the application directly.

Running Umami

You can simply run yarn start to start Umami, but it's highly recommended you use a process manager like PM2 which will handle restarts for you.

To run with PM2:

yarn global add pm2
cd umami
pm2 start yarn --name umami -- start
pm2 startup
pm2 save

Installing with Docker

Umami ships with a docker compose that contains the application and a PostgreSQL database.

To build the Docker container and start up with a Postgres database, run:

docker-compose up -d

Alternatively, if you want to use prebuilt images, you can pull the Umami Docker image with PostgreSQL support:

docker pull ghcr.io/umami-software/umami:postgresql-latest

Or with MySQL support:

docker pull ghcr.io/umami-software/umami:mysql-latest