Portabase Logo
Portabase DashboardInstallation

Environment Variables

Complete reference of .env configuration options.

Portabase provides flexibility through environment variables. These let you customize application behavior, database connection, authentication and storage.

If you use Docker Compose, set these variables in your .env file at the root of the project.


Project

General instance configuration.

VariableTypeOptionalDefaultDescription
PROJECT_URLstringNohttp://localhost:8887Public URL of your dashboard (e.g. https://backups.my-domain.com). Important for generated links.
PROJECT_SECRETstringNoNoneCritical. Secret used to encrypt sensitive data. Generate with openssl rand -hex 32.
PROJECT_NAMEstringYesPortabaseDisplay name in the UI (site title).
RETENTION_CRONstringYes0 7 * * *Schedule for automatic deletion of backups according to the retention policies.

Database

Configuration for the internal Portabase PostgreSQL connection.

VariableTypeOptionalDefaultDescription
DATABASE_URLstringYesNoneDatabase URL (e.g., postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}?schema=public). If not specified, the internal database will be used.

Email (SMTP)

Configuration for transactional email delivery (alerts, invitations).

If no configuration is provided, email-related features will be limited (no password reset, no email verification).

VariableTypeDefaultDescription
SMTP_HOSTstringNoneSMTP server address (e.g. smtp.resend.com).
SMTP_PORTstringNoneSMTP server port (e.g. 587).
SMTP_USERstringNoneSMTP username.
SMTP_PASSWORDstringNoneSMTP password.
SMTP_FROMstringNoneFrom email address (e.g. no-reply@your-domain.com).
SMTP_SECUREstringfalse

On this page