# Browser-based website installation (v4)

**No shell and no setup token are needed for the web application.** Use cPanel/Plesk File Manager and the MySQL Database Wizard or equivalents. After uploading, point your domain's HTTPS document root at the `public/` folder.

Before installation, temporarily block public access to `/install.php` using a web-server IP rule or your hosting panel's directory protection. The first visitor could otherwise create an administrator account, because the user requested no setup token. Delete `public/install.php` when done.

Open `https://YOURDOMAIN/install.php`. Enter MySQL host/port/database/username/password, desired first administrator, contact inbox and sender, optional SMTP STARTTLS details, Stripe secret key/webhook secret, and optional OpenAI key/model. The installer checks PHP 8.2+, `pdo_mysql`, `zip`, `curl`, `openssl` and `mbstring`, creates tables, encrypted service settings and first admin. It writes only database configuration plus `APP_KEY` to `.env` outside the document root and writes `.installed.lock` to block repeat installation.

Configure the Stripe webhook (`/webhook.php`) from the Stripe dashboard, then test a checkout. Back up and verify your APP_KEY separately. No API keys are stored in `.env`.

On a deployed v3 system, **do not use install.php**; run the admin-only `/upgrade.php` after backing up, as described in `V4_UPGRADE.md`.

## PBX deployment

Paid customers receive an expiring 7-day/25-download `wget` link to retrieve the exact paid ZIP on a FreePBX host. The PBX-side `install.sh` still requires local privileged shell access, FreePBX GraphQL OAuth credentials, dry run and a validated backup. Provider trunk plans and IVRs are manual guidance only.
