OwnMaily Docs

What is the Installation URL?

Getting Started

The Installation URL is the public address where your OwnMaily instance lives - for example, https://mail.yourdomain.com. OwnMaily uses this URL to build every link it puts inside your emails.

Getting it wrong is the most common setup mistake. The symptoms show up later, after you have already sent emails: broken unsubscribe links, tracking that never registers, images that do not load.

What it affects

Every outgoing email OwnMaily sends includes links built from this URL:

  • Open tracking pixel - if the URL is wrong, open rates show 0%
  • Click tracking - clicks are not recorded, and the redirect breaks
  • Unsubscribe link - subscribers cannot unsubscribe (CAN-SPAM violation)
  • Double opt-in confirmation - new subscribers stay pending forever
  • Uploaded images - images do not load in email clients

The most common mistake

Leaving it as http://localhost:4400.

This is the default value. It works fine when you are browsing the app from the same machine, but email clients are not on your machine. When Gmail or Apple Mail tries to load a tracking pixel at http://localhost:4400/track/open/..., it is pointing at nothing. The link silently fails.

Before sending to real subscribers, make sure this is set to a real, publicly reachable URL - not localhost, not a private IP, not an SSH tunnel address.

How to set it

There are two places the value lives, and both should match:

1. In your .env file (startup default)

Set INSTALLATION_URL in ~/ownmaily/.env before first launch:

INSTALLATION_URL=https://mail.yourdomain.com

The install script prompts you for this value. If you entered it correctly there, you are done with this step.

2. In Settings (takes effect immediately)

Go to Settings > General and update the Installation URL field. Changes take effect on the next campaign send - no restart needed.

The Settings value takes precedence over the .env value. When both are set, the database value wins.

Setup wizard gotcha

During the setup wizard (Step 3: General Settings), the Installation URL field is pre-filled from your browser's current address. If you open the wizard at https://mail.yourdomain.com/setup, it pre-fills correctly. If you access it through an SSH tunnel, a local port-forward, or a temporary IP address, the pre-fill will be wrong.

Always check this field before clicking Continue on Step 3.

HTTPS vs HTTP

Only use https:// if you have a reverse proxy (Caddy, Nginx, etc.) or platform handling TLS in front of the container. The OwnMaily app itself speaks plain HTTP - it does not terminate SSL.

If you set INSTALLATION_URL=https://... but the app is running on plain HTTP, email clients will see mixed-content warnings and some links will fail. Use http:// until your SSL is set up, then update the URL to https://.

Routing options

Subdomain (recommended)

Point mail.yourdomain.com to your server and proxy to OwnMaily's port via Caddy or Nginx. Set INSTALLATION_URL=https://mail.yourdomain.com.

Separate server

Run OwnMaily on its own VPS with its own domain. Simpler - no reverse proxy needed.

Bare IP (testing only)

You can set INSTALLATION_URL=http://203.0.113.42:4400 for initial testing. Do not send to real subscribers this way - bare IP addresses look suspicious to spam filters and email clients.

Example Caddy config (subdomain)

mail.yourdomain.com {
    reverse_proxy localhost:4400
}

Changing the URL after sending breaks links in old emails. Tracking pixels, unsubscribe links, and click redirects in already-delivered emails point to the old address permanently. Update the URL before you start sending to real subscribers.