.env file.
URL and Port
WEBUI_URL: public URL of OpenWebUI (example:http://localhost:3000)HTTP_WEB_PORT: host port mapped to OpenWebUI containerWEBUI_SECRET_KEY: app secret key (generate strong random value)
Database
POSTGRES_USER: Postgres usernamePOSTGRES_PASSWORD: Postgres passwordPOSTGRES_DB: Postgres database namePOSTGRES_HOST: Postgres host/service namePOSTGRES_PORT: Postgres port
Admin Provisioning
X_WEBUI_ADMIN_USER: initial admin display nameX_WEBUI_ADMIN_EMAIL: initial admin emailX_WEBUI_ADMIN_PASS: initial admin passwordWEBUI_AUTH: enable web authentication (True/False)ENABLE_SIGNUP: allow signup on first boot (True/False)ENABLE_LOGIN_FORM: enable login form (True/False)
Note: keep ENABLE_SIGNUP=True on first start so admin account auto-provisioning
works. After first boot, you can disable it to run in single-user or private modes.
OpenAI-Compatible Provider (Optional)
ENABLE_OPENAI_API: auto-provision provider settings (True/False)OPENAI_API_BASE_URL: provider base URL (example:https://openrouter.ai/api/v1)OPENAI_API_KEY: provider API keyOPENAI_DEFAULT_MODEL: default model ID
Workspace Model (Optional)
CREATE_CUSTOM_WORKSPACE_MODEL:Trueinstalls the bundled model, or set a file name frommodels/to install that fileOWUI_MODEL_PROMPT: replaces the model’s system promptOWUI_MODEL_PROMPT_APPEND: appends text to the model’s system prompt, separated by a blank line
CREATE_CUSTOM_WORKSPACE_MODEL installs a model.
See Workspace Models for details.
This installs only during first-start initialization — the setup that runs only once, the first time the container boots, gated on a marker file. Setting
CREATE_CUSTOM_WORKSPACE_MODEL on an already-running instance does not install it retroactively.Runtime
ENV: runtime mode (example:dev)UVICORN_WORKERS: number of Uvicorn workersUSER_AGENT: outgoing user agent string