Skip to main content

Environment Variables

Frontend​

Frontend variables are loaded by Vite from .env.development, .env.production, or .env.test. They are embedded in the frontend bundle at build time and are visible to browser users, so never use VITE_* variables for secrets.

VariableDefaultDescription
VITE_API_URLBrowser originBackend origin for web mode. Standard Docker deployments use the nginx proxy and should leave this unset.
VITE_ENABLE_MOCKSfalseStarts the MSW browser worker when set to true.

Frontend defaults and VITE_* access are centralized in apps/renderer/src/config.ts.

Backend​

Backend variables are read at runtime. Electron loads the root .env file; the direct webserver inherits variables from its shell or process manager; Docker Compose passes variables to the backend container.

VariableDefaultDescription
FE_SERVER_URLhttp://127.0.0.1:5173Electron development URL and allowed webserver CORS origin.
USERPROFILECurrent working directoryDefault directory for Electron file dialogs; normally set by Windows.
DEV_SERVER_URL127.0.0.1Address on which the backend webserver listens.
PORT3000Backend webserver port.

Backend defaults and parsing are centralized in packages/core/src/config.ts.

For NODE_ENV, PostgreSQL pool tuning, webserver session lifecycle, and Docker-only variables, see the Self-Hosting (Docker) deployment environment variables.