Configuration Reference

A self-hosted DBO Studio is configured with environment variables. There is no config file. The desktop app sets what it needs on its own, so you only need this page when you host DBO Studio.

Common setups

Personal server, no login

Only you can reach the host, for example over a VPN or on localhost:

bash
APP_ENV=docker
APP_PORT=9000

Team server with login

Other people can reach the host. Put TLS in front of it (see Docker) and turn login on:

bash
APP_ENV=docker
APP_PORT=9000
APP_PUBLIC_URL=https://dbo.example.com
APP_AUTH_MODE=local
APP_ALLOWED_ORIGINS=https://dbo.example.com

On first start DBO Studio prints a one-time link to create the admin account. See Authentication and users.

Server

VariableDefaultDescription
APP_PORT9000 in the Docker image, 8080 otherwisePort DBO Studio listens on.
APP_ENVdocker in the Docker imageWhere data is stored by default. See Storage.
APP_CLIENTwebweb or desktop. The desktop app sets desktop itself. Leave it as web on a server.

Authentication

VariableDefaultDescription
APP_AUTH_MODEsee belowlocal requires login. none turns login off.
APP_ADMIN_EMAILunsetOptional. Creates the first admin at startup when login is on and no account exists.
APP_ADMIN_PASSWORDunsetPassword for that admin: 8 to 40 characters, with a letter and a number. It must be changed at first sign-in.
APP_ALLOWED_ORIGINSunsetComma-separated list of origins allowed to call the API from a browser. Required when login is on.

When APP_AUTH_MODE is not set, DBO Studio keeps the behavior of older versions: login is on if any account exists or both APP_ADMIN_* variables are set, and off otherwise. It logs a warning so you can set the mode explicitly. Any value other than none or local stops DBO Studio at startup.

Without login, DBO Studio also accepts browser requests from localhost origins. With login on, only the origins in APP_ALLOWED_ORIGINS are accepted.

bash
APP_ALLOWED_ORIGINS=https://dbo.example.com,https://dbo.internal.example.com

Public URLs

VariableDefaultDescription
APP_PUBLIC_URLhttp://127.0.0.1:<port>The address people use to open DBO Studio, without a trailing slash. Used for MCP and for secure cookies.
APP_MCP_PUBLIC_URL<APP_PUBLIC_URL>/api/mcpOverride the MCP endpoint shown to AI tools.

When APP_PUBLIC_URL starts with https://, the session cookie is marked Secure.

Storage

DBO Studio keeps its own data in a small SQLite database, separate from the databases you connect to. A key file next to it encrypts saved passwords and API keys.

VariableDefaultDescription
APP_DATABASE_PATHdepends on APP_ENVApp database file.
APP_SECRET_KEY_PATHnext to the app dataEncryption key file. Created on first start with mode 0600.
APP_LOG_PATHnext to the app dataLog directory.

Default locations by APP_ENV:

APP_ENVApp data
docker/backend/data/ in the container
local~/Library/Application Support/dbo/ on macOS, %APPDATA%\dbo\ on Windows, ~/.dbo/ on Linux
testingdata/testing_dbo.db, for automated tests

Warning: Back up the app database and the key file together. Without the key file, saved passwords and API keys cannot be decrypted.

Docker Compose example

yaml
services:
  dbo:
    image: ghcr.io/dbo-studio/dbo/dbo:latest
    restart: unless-stopped
    ports:
      - "9000:9000"
    volumes:
      - ./dbo-data:/backend/data
    environment:
      APP_PUBLIC_URL: https://dbo.example.com
      APP_AUTH_MODE: local
      APP_ALLOWED_ORIGINS: https://dbo.example.com

Previous

Authentication and Users

Next

Security Model