Skip to content
Docs for Flare v2.1.0Latest stable · 10d28125Build details ↗Versions & changes
View docs

Configuration reference ​

Flare separates server connection details from instance preferences. Configure PostgreSQL and authentication in the environment. Configure storage, registration, OIDC, appearance, and most product behavior in Settings. Those settings are stored in PostgreSQL, so they survive container recreation when the database persists.

How changes take effect ​

Configuration sourceUsed forHow to apply
Deployment environmentDatabase, public origin, secrets, logging, webhook network policyRecreate/redeploy the app process
Settings in PostgreSQLInstance behavior, storage credentials, access, design, emailSave in the appropriate Settings section
Profile in PostgreSQLPersonal appearance, upload defaults, recipes, tokens, webhooksSave in Profile
Email environment overridesAny operator-facing email settingRecreate/redeploy; overridden controls are marked Managed by environment

For email, precedence is environment or secret file → saved value → default. Removing an override reveals the saved fallback; the override is not copied into the database. Other settings do not have an equivalent generic environment mapping.

Core environment variables ​

VariableDefaultPurpose
DATABASE_URLRequiredPostgreSQL connection string, for example postgresql://flare:password@db:5432/flare?schema=public
NEXTAUTH_URLSet explicitlyCanonical public origin, including https://; used for authentication, generated links, origin checks, and email's default public URL
NEXTAUTH_SECRETSet explicitlyStable random authentication secret; also the fallback encryption key for stored SMTP/outbox and webhook secrets
LOG_LEVELinfo in production; debug in developmentfatal, error, warn, info, debug, or trace
FLARE_WEBHOOK_ALLOW_PRIVATE_NETWORKDisabledOnly the exact value true permits HTTP webhook URLs and private/reserved destination addresses
FLARE_EMAIL_ENCRYPTION_KEYNEXTAUTH_SECRETOptional dedicated key for encrypted SMTP credentials, mail payloads, and webhook signing secrets; at least 32 characters
FLARE_EMAIL_ENCRYPTION_KEY_FILEUnsetRead the dedicated encryption key from a file; mutually exclusive with the direct variable
FLARE_RELEASE_CHANNELstablerolling selects prerelease update-check behavior and display; other values resolve to stable
FLARE_COMMIT_SHAUnsetBuild identity shown for rolling releases; use the actual source commit

DATABASE_URL and NEXTAUTH_SECRET do not have Flare-provided _FILE variants. If your host supplies these through secret files, use its supported environment injection mechanism. Never assume every environment variable in this table supports a _FILE suffix.

Use a stable, random NEXTAUTH_SECRET of at least 32 characters from the beginning. Creating webhooks needs encryption even when account email is disabled. Changing the active encryption key without migrating encrypted values prevents existing secrets from being decrypted; plan key rotation.

Webhook network access ​

The default webhook policy accepts public HTTPS destinations only. Flare resolves and validates the destination at delivery time. Setting FLARE_WEBHOOK_ALLOW_PRIVATE_NETWORK=true lets instance users configure receivers on networks reachable by the server, including HTTP services. Enable it only when that access matches your deployment's intended users and network boundaries. There is no environment-configured per-host allowlist in this release.

Container and framework variables ​

These belong to the app runtime or build tooling, rather than saved instance configuration.

VariableOfficial image behavior
PORT3000; the bundled Docker health check also targets port 3000, so change that check if you change the port
HOSTNAMESet to 0.0.0.0 in the image
NODE_ENVproduction; development uses pnpm dev
NEXT_TELEMETRY_DISABLED1 in the image; controls Next.js telemetry
NEXT_RUNTIMESet by Next.js; Flare initializes background workers for the Node runtime
METICULOUS_BUILDDocker build argument, default false; true includes production browser source maps for visual testing
NEXT_PUBLIC_METICULOUS_RECORDING_TOKENOptional public recording token for development/preview or explicitly enabled test deployments
METICULOUS_RECORDING_ENABLEDExplicit true enables recording eligibility outside development/preview when a token exists
METICULOUS_BACKEND_RECORDER_MODEreplay enables the backend replay path used by visual tests
VERCEL_ENVA platform marker; preview enables recording eligibility when a recording token is present

The Dockerfile also sets Corepack/pnpm installation variables (COREPACK_ENABLE_DOWNLOAD_PROMPT, COREPACK_HOME, npm_config_verify_deps_before_run, and HUSKY) to make its packaged runtime work. They are not Flare feature controls. Build identity arguments FLARE_RELEASE_CHANNEL and FLARE_COMMIT_SHA are baked into the official image by release workflows.

Meticulous's hosted CI workflow has been retired. Its recorder variables and disposable test image remain available for local visual testing; ordinary production recording still requires explicit opt-in and a recording token. METICULOUS_API_TOKEN authenticates the optional CLI, not Flare's server or users, and is no longer required as a repository Actions secret.

Email environment variables ​

Every variable in the following tables also accepts a _FILE variant. For example, FLARE_EMAIL_SMTP_PASSWORD_FILE=/run/secrets/smtp_password reads that file's contents, trimming trailing whitespace. Set one of the direct variable or its _FILE variant. Booleans must be exactly true or false; numbers must be nonnegative integer strings and satisfy the listed range.

Connection and sending ​

VariableDefaultAccepted values / effect
FLARE_EMAIL_ENABLEDfalseTurns automatic email sending and local email policies on or off
FLARE_EMAIL_SMTP_HOSTEmptySMTP server hostname
FLARE_EMAIL_SMTP_PORT4651–65535
FLARE_EMAIL_SMTP_SECURITYtlstls, starttls, none
FLARE_EMAIL_SMTP_AUTHENTICATIONtrueWhether SMTP login is required
FLARE_EMAIL_SMTP_USERNAMEEmptySMTP username
FLARE_EMAIL_SMTP_PASSWORDEmptySMTP password; prefer its _FILE form for mounted secrets
FLARE_EMAIL_SMTP_CAEmptyPEM custom certificate authority content, not a filename; use _FILE to read a PEM file
FLARE_EMAIL_SMTP_TIMEOUT_SECONDS153–120 seconds
FLARE_EMAIL_FROM_NAMEFlareSender display name
FLARE_EMAIL_FROM_ADDRESSEmptyProvider-authorized sender email address
FLARE_EMAIL_REPLY_TOEmptyOptional reply-to email address
FLARE_EMAIL_PUBLIC_URLEmpty → NEXTAUTH_URLPublic account-link base; HTTPS required except for loopback testing

Recovery, verification, and address changes ​

VariableDefaultAccepted values / effect
FLARE_EMAIL_RECOVERY_ENABLEDfalsePassword recovery for verified local accounts
FLARE_EMAIL_RECOVERY_TOKEN_MINUTES305–120 minutes
FLARE_EMAIL_RECOVERY_ROTATE_UPLOAD_TOKENfalseRotate the legacy upload token after a successful password reset
FLARE_EMAIL_VERIFICATION_MODEoffoff, optional, new_users, all_users
FLARE_EMAIL_VERIFICATION_GRACE_DAYS70–90 days for existing users when all-user enforcement is activated
FLARE_EMAIL_VERIFICATION_ADMIN_CREATEDinheritinherit or exempt for accounts created by administrators
FLARE_EMAIL_VERIFICATION_TRUST_OIDCfalseAccept trusted provider proof for matching email when email_verified is true
FLARE_EMAIL_VERIFICATION_TOKEN_HOURS241–168 hours
FLARE_EMAIL_CHANGES_ENABLEDtrueAllow confirmed address changes when email is enabled
FLARE_EMAIL_CHANGES_REQUIRE_OLD_EMAILfalseRequire old-address approval as well as new-address confirmation

Policy activation timestamps and the internal applied-mode marker are server-owned; they cannot be overridden through environment variables. Entering all_users starts a fresh existing-user grace window. Environment policy changes have no dashboard confirmation step, so verify an administrator's recovery address or exemption before applying them.

Limits and delivery ​

VariableDefaultAllowed range
FLARE_EMAIL_LIMITS_RESEND_SECONDS6030–3600
FLARE_EMAIL_LIMITS_ADDRESS_PER_HOUR51–100
FLARE_EMAIL_LIMITS_IP_PER_HOUR201–1000
FLARE_EMAIL_LIMITS_DAILY_LIMIT5001–100000
FLARE_EMAIL_DELIVERY_MAX_ATTEMPTS31–10
FLARE_EMAIL_DELIVERY_RETRY_SECONDS6010–3600; starting delay for exponential backoff
FLARE_EMAIL_DELIVERY_CONCURRENCY21–10 across the instance
FLARE_EMAIL_DELIVERY_RETENTION_DAYS141–90

Email branding ​

VariableDefault
FLARE_EMAIL_BRANDING_INSTANCE_NAMEFlare
FLARE_EMAIL_BRANDING_LOGO_URLEmpty
FLARE_EMAIL_BRANDING_ACCENT_COLOR#6366f1; six-digit hex color
FLARE_EMAIL_BRANDING_FOOTEREmpty
FLARE_EMAIL_BRANDING_SUPPORT_ADDRESSEmpty
FLARE_EMAIL_BRANDING_SUBJECT_PREFIXEmpty
FLARE_EMAIL_BRANDING_VERIFICATION_SUBJECTVerify your email address
FLARE_EMAIL_BRANDING_RESET_SUBJECTReset your password
FLARE_EMAIL_BRANDING_CHANGE_SUBJECTConfirm your new email address
FLARE_EMAIL_BRANDING_INTRO_TEXTEmpty

Text is escaped into Flare's HTML and plain-text messages. These settings are not arbitrary executable templates. See the email guide for a staged rollout and delivery diagnostics.

Settings stored in the database ​

These defaults describe a new instance before your setup choices. Existing instances retain saved settings during upgrades.

SettingDefaultGuide
Public registrationEnabled; empty disabled messageAccess and users
Background OCREnabledGeneral settings
Credits footerShownAppearance
Storage providerLocalStorage
S3 credentials / endpointEmpty; force path style offS3
Maximum file size100 MBLimits
Ordinary-user quotaDisabled; 10 GB when enabledQuotas
OIDCDisabledSSO
OIDC auto-provisionEnabledSSO
OIDC verified-email requirementEnabledSSO
OIDC auto-loginDisabledSSO
OIDC buttonSign in with SSOSSO
Legacy appearanceDark, default Flare colors, no custom faviconAppearance
Studio themeDisabled; dark default mode; glow background; Inter font; radius 0.75Appearance
Default share styleFramed; show uploader, filename, and size; contain imagesSharing design
Custom CSS / head HTMLEmptyAdvanced appearance

There are no supported FLARE_STORAGE_*, FLARE_OIDC_*, FLARE_REGISTRATION_*, or quota environment variables in the current implementation. Edit those controls in Settings. The FLARE_URL, FLARE_TOKEN, and FLARE_WEBHOOK_SECRET names used by example client scripts configure those scripts, not the server.

Saved general and access fields ​

The following paths are relative to settings in Flare's saved configuration. They help operators compare a backup or a configuration export with the interface; use Settings to change them so validation and related updates run. They are not environment variable names.

Saved pathInitial valueMeaning
general.registrations.enabledtrueAllow local account registration
general.registrations.disabledMessageEmpty stringMessage shown when registration is closed
general.storage.providerlocallocal or s3; one active provider for the instance
general.storage.s3.bucketEmpty stringExisting bucket name
general.storage.s3.regionEmpty stringProvider region
general.storage.s3.accessKeyIdEmpty stringConfigured S3 credential identifier
general.storage.s3.secretAccessKeyEmpty stringConfigured S3 credential secret; protect database backups
general.storage.s3.endpointEmpty stringOptional custom S3 API endpoint; saved settings normalize a missing scheme to HTTPS and remove trailing slashes
general.storage.s3.forcePathStylefalseUse path-style addressing with a custom endpoint
general.storage.quotas.enabledfalseApply the shared allowance to ordinary users
general.storage.quotas.default.value10Allowance amount per ordinary user
general.storage.quotas.default.unitGBDashboard choices are MB or GB, using binary units
general.storage.maxUploadSize.value100Maximum size of one uploaded file
general.storage.maxUploadSize.unitMBDashboard choices are MB or GB, using binary units
general.credits.showFootertrueShow the instance's Flare credit footer
general.ocr.enabledtrueQueue background image text extraction
general.oidc.enabledfalseEnable the configured OIDC provider
general.oidc.issuerEmpty stringProvider issuer; discovery path is appended by Flare
general.oidc.clientIdEmpty stringOIDC application identifier
general.oidc.clientSecretEmpty stringOIDC application secret; protect database backups
general.oidc.buttonTextSign in with SSOSign-in button label
general.oidc.autoProvisiontrueCreate eligible new OIDC User accounts
general.oidc.requireEmailVerifiedtrueRequire provider verification for a new identity
general.oidc.enforceSsofalseOIDC auto-login and suppression of local email recovery; explicit local password login remains available

Setup also maintains general.setup.completed (initially false) and general.setup.completedAt (initially null). These are lifecycle state, not controls for recreating the first administrator. The top-level version is internal configuration-migration metadata, not the installed Flare release number. Do not reset setup fields or change version markers as an upgrade procedure.

Saved appearance fields ​

Legacy appearance remains in settings.appearance: theme defaults to dark; favicon is initially null; customColors is the original HSL palette. settings.advanced.customCSS and settings.advanced.customHead are empty strings initially. The favicon and custom styles are separate from studio packs.

The studio's published document lives under settings.customization.published. The same shape is used for a saved draft and previous document. Paths in this table are relative to that appearance document.

Appearance pathInitial valueChoices or limit
brand.nameFlare1–60 characters
brand.taglineA free, modern, open source file upload platformUp to 180 characters
brand.logoLightEmpty stringEmbedded PNG/JPEG/WebP data URL, up to 256 KB
brand.logoDarkEmpty stringEmbedded PNG/JPEG/WebP data URL, up to 256 KB
brand.footerTextFlare is a free, open source, self-hostable file host.Up to 200 characters
theme.enabledfalseApply studio palettes rather than the original theme behavior
theme.defaultModedarksystem, light, dark
theme.lightLight palette belowFull palette with six-digit hex colors
theme.darkDark palette belowFull palette with six-digit hex colors
theme.radius0.750–1.5 rem
theme.backgroundglowglow, plain, grid
theme.fontinterinter, system, mono
sharing.defaultStyleframedminimal, framed, delivery
sharing.showUploadertrueShow uploader attribution
sharing.showFilenametrueShow filename
sharing.showSizetrueShow formatted file size
sharing.showFooternullnull inherits general.credits.showFooter; true/false override
sharing.imageFitcontaincontain shows the whole image; cover fills the frame
sharing.titleTemplateEmpty stringAutomatic title when empty; up to 500 characters
sharing.descriptionTemplateEmpty stringAutomatic description when empty; up to 500 characters

Both social templates support , , , and . Hidden details are omitted. Appearance describes the publish and recovery workflows.

The customization wrapper also contains version (currently 1), revision (initially 0), draft and previous (initially null), and publishedAt (initially null). Flare manages these fields during saves, publishing, imports, and restoration. Revision checks protect against concurrent editors; do not strip or manually increment them to force a stale save.

Palette fields and defaults ​

The studio uses the same field names for theme.light and theme.dark. The legacy appearance.customColors map uses these names too, with HSL components rather than hex values. The full starting values are:

FieldStudio lightStudio darkLegacy HSL
background#f8fafc#020817222.2 84% 4.9%
foreground#0f172a#f8fafc210 40% 98%
card#ffffff#020817222.2 84% 4.9%
cardForeground#0f172a#f8fafc210 40% 98%
popover#ffffff#020817222.2 84% 4.9%
popoverForeground#0f172a#f8fafc210 40% 98%
primary#0f172a#f8fafc210 40% 98%
primaryForeground#f8fafc#0f172a222.2 47.4% 11.2%
secondary#e2e8f0#1e293b217.2 32.6% 17.5%
secondaryForeground#0f172a#f8fafc210 40% 98%
muted#f1f5f9#1e293b217.2 32.6% 17.5%
mutedForeground#475569#94a3b8215 20.2% 65.1%
accent#e2e8f0#1e293b217.2 32.6% 17.5%
accentForeground#0f172a#f8fafc210 40% 98%
destructive#dc2626#991b1b0 62.8% 30.6%
destructiveForeground#ffffff#f8fafc210 40% 98%
border#cbd5e1#1e293b217.2 32.6% 17.5%
input#cbd5e1#1e293b217.2 32.6% 17.5%
ring#64748b#cbd5e1212.7 26.8% 83.9%

Account-specific settings are stored separately from the instance configuration: personal theme preference, upload defaults and profiles, tool options, scoped tokens, and webhook destinations are managed in Profile. Their values do not override operator limits or grant administrator permissions. See the user handbook and API authentication.

Test-only database variables ​

The repository's integration suites use explicit disposable databases: FLARE_SETUP_DATABASE_URL, FLARE_FOLDERS_DATABASE_URL, FLARE_TAGS_DATABASE_URL, FLARE_CUSTOMIZATION_DATABASE_URL, FLARE_EMAIL_AUTH_DATABASE_URL, FLARE_EMAIL_DELIVERY_DATABASE_URL, and FLARE_EMAIL_CONFIG_DATABASE_URL. They are not production connection settings. These tests delete fixtures; never point them at an application database.