Documentation Index
Fetch the complete documentation index at: https://mintlify.com/formbricks/formbricks/llms.txt
Use this file to discover all available pages before exploring further.
Overview
This page provides a comprehensive reference for all environment variables available in Formbricks. Environment variables allow you to configure your self-hosted instance without modifying code.Required Variables
These variables are mandatory for Formbricks to function properly.Core Configuration
The base URL where your Formbricks instance is hosted.Example:
http://localhost:3000 or https://formbricks.example.comShould be the same as
WEBAPP_URL. Required for NextAuth authentication.If your application uses a custom base path, specify the full route to the API endpoint.Example: https://example.com/custom-route/api/authEncryption key for securing sensitive data. Generate using:
Secret for running cron jobs securely. Generate using:
PostgreSQL database connection string.Example:
postgresql://postgres:postgres@localhost:5432/formbricks?schema=publicEmail Configuration (Required for email features)
Email address used as the sender for all outgoing emails.Example:
noreply@example.comDisplay name for the sender email address.Default:
FormbricksSMTP server hostname.Example:
smtp.gmail.com or localhostSMTP server port.Common values:
587 (TLS), 465 (SSL), 1025 (local development)Username for SMTP authentication.
Password for SMTP authentication.
Optional Variables
Logging
Minimum log level to output.Options:
debug, info, warn, error, fatalBase Path
Deploy the application under a sub-path of a domain. Can only be set at build time.Example:
/formbricksSMTP Advanced Configuration
Enable TLS for SMTP connection (port 465).Options:
0 (disabled), 1 (enabled)Require SMTP authentication.Options:
0 (no authentication), 1 (authentication required)Accept connections without requiring authorization from the list of supplied CAs.Options:
0 (accept unauthorized), 1 (reject unauthorized)Storage Configuration
AWS S3 access key ID or compatible storage service credentials.
AWS S3 secret access key or compatible storage service credentials.
AWS region for S3 bucket.Example:
us-east-1, eu-west-1Name of the S3 bucket for file storage. Required for file uploads in serverless environments.
Custom endpoint URL for S3-compatible storage services (e.g., StorJ, MinIO).Leave empty if using Amazon S3.Example:
https://gateway.storjshare.ioForce path style for S3-compatible storage.Options:
0 (disabled), 1 (enabled)Public domain for all client-facing routes. Falls back to
WEBAPP_URL if not set.Example: https://survey.example.comFeature Toggles
Disable email verification for new users.Note: Requires SMTP configuration if enabled.Options:
0 (enabled), 1 (disabled)Disable password reset functionality.Note: Requires SMTP configuration if enabled.Options:
0 (enabled), 1 (disabled)Disable email/password login.Options:
0 (enabled), 1 (disabled)Disable the ability for invited users to create accounts.Options:
0 (enabled), 1 (disabled)Legal & Compliance
URL to your privacy policy. Displayed in footer of signup and public pages.
URL to your terms of service. Displayed in footer of signup and public pages.
URL to your imprint/legal notice. Displayed in footer of signup and public pages.
Physical address for imprint/legal notice.
Security & Bot Protection
Cloudflare Turnstile site key for bot protection in signup flow.
Cloudflare Turnstile secret key for bot protection.
Google reCAPTCHA v3 site key for bot protection.
Google reCAPTCHA v3 secret key for bot protection.
OAuth Providers
GitHub OAuth application client ID.
GitHub OAuth application client secret.
Google OAuth application client ID.
Google OAuth application client secret.
Azure Active Directory OAuth application client ID.
Azure Active Directory OAuth application client secret.
Azure Active Directory tenant ID.
OpenID Connect (OIDC)
OIDC client ID.
OIDC client secret.
OIDC issuer URL.
Display name for OIDC provider in login UI.
OIDC token signing algorithm.Example:
RS256SAML SSO
Separate PostgreSQL database URL for SAML SSO configuration.Example:
postgresql://postgres:postgres@localhost:5432/formbricks-samlAsset Configuration
Configure to ship JS & CSS files from a complete URL instead of the current domain.
Integrations
Notion OAuth client ID for Notion integration.
Notion OAuth client secret for Notion integration.
Google Sheets OAuth client ID.
Google Sheets OAuth client secret.
Google Sheets OAuth redirect URL.
Airtable OAuth client ID.
Slack OAuth client ID for Slack integration.
Slack OAuth client secret for Slack integration.
Unsplash API access key for image integration.
Billing (Enterprise)
Stripe secret key for payment processing.
Stripe webhook secret for verifying webhook signatures.
Enterprise Features
Enterprise license key to unlock enterprise features.
Automatically assign new SSO users to a specific organization.Insert an existing organization ID or generate a valid CUID at getuniqueid.com.
Skip invite requirement for SSO users.Options:
0 (require invite), 1 (skip invite)Minimum role required for user management from UI.Options:
owner, manager, disabledMarketing & Analytics
Brevo (formerly Sendinblue) API key for sending new users to Brevo.
Brevo list ID to add new users to.
Performance & Caching
Redis connection URL for caching (uses Next.js in-memory cache if not provided).Example:
redis://localhost:6379Redis HTTP URL for rate limiting (uses in-memory LRU cache if not provided).You can use a service like Webdis for this.
Disable rate limiting across the Formbricks app.Options:
0 (enabled), 1 (disabled)Monitoring & Observability
OpenTelemetry OTLP endpoint (base URL, exporters append
/v1/traces and /v1/metrics).Example: http://localhost:4318OpenTelemetry protocol.Example:
http/protobufService name for OpenTelemetry.Example:
formbricksResource attributes for OpenTelemetry.Example:
deployment.environment=developmentTrace sampler for OpenTelemetry.Example:
parentbased_traceidratioTrace sampler argument for OpenTelemetry.Example:
1Enable Prometheus metrics.Options:
0 (disabled), 1 (enabled)Port for Prometheus metrics exporter.
Sentry DSN for error tracking and performance monitoring.
Sentry authentication token. Picked up automatically by Sentry Build Plugin for uploading source maps.
Environment label for errors in Sentry dashboard.Example:
production, stagingSupport & Chat
Chatwoot base URL for customer support chat.
Chatwoot website token for customer support integration.
Audit Logging
Enable audit logging.Options:
0 (disabled), 1 (enabled)Include user IP addresses in audit logs.Options:
0 (disabled), 1 (enabled)Session Configuration
Maximum session age in seconds.Default:
86400 (24 hours)Environment Type
Internal environment identifier.Options:
production, stagingTranslation
Lingo.dev API key for translation generation.
Environment File Example
You can copy the.env.example file from the Formbricks repository as a starting point:
.env file with your specific configuration values.