Skip to main content
Environment variables are the primary configuration mechanism for Ragen AI. The web application, API server, and background worker all read their configuration from the process environment at boot, and the same variable names apply whether you are running locally with a .env file or deploying to a container orchestrator. A required variable is required only once you have chosen a provider that needs it; everything else has a working default in code.
Looking for a specific variable? The configuration reference lists every one, generated from the schemas each application validates against at boot — so it cannot disagree with the code. This page explains the choices: which provider to pick, and what each one implies.

Provider Settings

One variable selects an implementation for each provider, and that choice determines which additional variables you must set.
Choose your storage backend with STORAGE_PROVIDER, which defaults to local.
Files are written to the container filesystem. STORAGE_LOCAL_PATH defaults to ./data/storage, so nothing is mandatory — but every process that touches files needs access to the same mounted volume.

Core Settings

Database, vector store, Redis and Temporal are listed with their config fields and requiredness in the configuration reference, which is generated from the schemas the applications validate against at boot. They are not repeated here, because a second copy is a copy that goes wrong: the last hand-written reference called S3_ENDPOINT_URL required when it is optional, omitted S3_SESSION_TOKEN, and described an encryption failure backwards. One that decides how model calls are made is worth naming here, and is covered properly in Model gateway: There is no variable selecting a gateway mode any more: Ragen calls providers itself, and an external gateway is a route rather than a setting.

Auth Settings

Generate secret values with:

Feature Flags

Feature flags control optional capabilities. Most are off by default and enabled by setting them to 1; FEATURE_FLAG_DOC_SUMMARIES is the exception — it defaults on and is disabled by setting it to 0.