Plausible Analytics is an incredible alternative to Google Analytics. And it’s incredible in its own right too, coming with a number of advantages, including:
- it’s lightweight
- it’s privacy-friendly
- it’s open source
The fact that they permit you to self-host your own instance is quite the added bonus.
But setting up that self-hosted instance isn’t always a walk in the park. It requires time, patience, and a good amount of familiarity with the terminal and virtual machines as a whole. You could do it, but it might not always be expedient to go that route.
The Goal of this Product
The Plausible Bootstrapper’s goal is to remove as much hassle out of self-hosting Plausible Analytics as possible. At it’s core, it’s just a script you execute on an Ubuntu virtual machine. But it does a lot.
What It Does
By running the Plausible Bootstrapper script with the appropriate input, you’ll come out with a fully functional instance of Plausible Analytics. To get there, it does the following:
- Install system dependencies. This includes things like curl, Docker, openssl, and whatever’s in-between. Depending on your provider, many of these things might already be there. In those cases, those dependencies are skipped.
- Download, install, and configure Plausible Analytics. It’ll stick everything in the
/opt/plausibledirectory of your box, and will require a bit of information from you (a domain where you’d like to host your analytics, username, password, etc.).
- Set up nginx. It’s useless unless it’s being served to the world. That’s what this step is about. An nginx reverse proxy is set up and connected to your Plausible instance.
- Install an SSL certificate. It’ll automatically renew too, so you won’t have to worry about it expiring later on.
The script is designed in non-destructive way as well, meaning that if you run it multiple times on the same machine, it won’t below away the instance that’s already there. It’s a bit of reassurance you won’t lose any data you’ve collected.
- an Ubuntu virtual machine
- access to that machine (via SSH or whatever)
Before you run anything, you’ll need to set up an
A record in your DNS registry that points the IP address of your server. For example, this configuration would make the instance accessible at
This record must match the
PB_BASE_URL environment variable you’ll set later on.