Application environment. development value makes sure all errors will be shown explicitly, making easier remote debugging
SELF_HOSTED
true
Set to true if you're self-hosting Dawarich
APPLICATION_HOSTS
localhost,my.domain.com
Application hosts, provide multiple if you want your Dawarich instance to be available by multiple domains/ip addresses. Don't put protocols here, only host names.
APPLICATION_PROTOCOL
http
Application protocol. Change to https if you want your Dawarich instance to be served via SSL
DOMAIN
nil
Public hostname used to build absolute URLs in outgoing emails (family invitations, digest emails, password resets). Required in production — leaving it unset will cause email delivery to fail with a URL generation error. No protocol, no trailing slash. Example: dawarich.example.com.
TIME_ZONE
Europe/London
Time zone. Full list of supported timezones available on Github
DISTANCE_UNIT
km
Distance unit. For miles, change to mi. All settings still should be provided in meters/kilometers
See Configuring SMTP for provider-specific examples (Office 365, Gmail, Brevo, local Postfix), the email link protocol behavior, and a troubleshooting matrix.
Environment Variable
Default Value
Description
SMTP_SERVER
nil
Your SMTP server hostname
SMTP_PORT
nil
Your SMTP port (typically 587 for TLS)
SMTP_DOMAIN
nil
HELO/EHLO domain. For transactional relays (Brevo, Mailgun, SendGrid, Postmark, Resend), set this to your verified sender domain — typically the part after @ in SMTP_FROM.
SMTP_USERNAME
nil
Your SMTP username
SMTP_PASSWORD
nil
Your SMTP password
SMTP_FROM
nil
Email address to send emails from
SMTP_AUTHENTICATION
plain
Auth mechanism. Common values: plain, login (Office 365 / Microsoft 365 requires this), cram_md5. digest_md5, gssapi, ntlm, xoauth2 also accepted but rarely useful.
SMTP_STARTTLS
true
Opportunistic TLS upgrade on port 587. Leave true for internet-facing relays. Set false only for plain SMTP on port 25 to a trusted local relay. No effect on port 465 (SMTPS / implicit TLS).
SMTP_OPEN_TIMEOUT
5
Seconds to wait for the TCP connection. Bump to 25 for slow providers.
SMTP_READ_TIMEOUT
5
Seconds to wait for an SMTP response. Bump to 25 for slow providers.
Email is required for:
Password reset
Year-end digest emails
Family invitation emails
Email links are sent as https:// regardless of APPLICATION_PROTOCOL. Plain-HTTP self-hosters need a one-line initializer override — see Configuring SMTP → Email link protocol.
Important note on Prometheus exporter: even if you want to use it, make sure you have PROMETHEUS_EXPORTER_ENABLED set to false in dawarich_sidekiq container. Otherwise, you'll end up with two exporters and will have to deal with duplicate metrics. The PROMETHEUS_EXPORTER_HOST for dawarich_sidekiq should be set to dawarich_app or your name of the container.
Primary key for encrypting OTP secrets. Production deployments should set a unique value.
OTP_ENCRYPTION_DETERMINISTIC_KEY
Built-in default
Deterministic key for OTP encryption. Production deployments should set a unique value.
OTP_ENCRYPTION_KEY_DERIVATION_SALT
Built-in default
Salt for OTP key derivation. Production deployments should set a unique value.
Tip
These keys are used by Active Record Encryption to secure 2FA (TOTP) secrets. If not set, built-in defaults are used — fine for most self-hosted setups. For maximum security, generate unique values with openssl rand -hex 32 and set them in your environment.