OpenHands Enterprise can connect to an external PostgreSQL instance instead of using the bundled database. This is useful when you have existing database infrastructure, need specific backup/recovery procedures, or require high availability configurations.Documentation Index
Fetch the complete documentation index at: https://docs.openhands.dev/llms.txt
Use this file to discover all available pages before exploring further.
PostgreSQL Version
OpenHands Enterprise requires PostgreSQL 16.4.0 or above. PostgreSQL 17 is also supported.Required Databases
OpenHands Enterprise uses the following databases:| Database | Purpose |
|---|---|
openhands | Core application data |
bitnami_keycloak | Identity and access management |
litellm | LLM proxy configuration and usage tracking |
runtime_api_db | Runtime/sandbox management |
automations | Scheduled tasks and automation workflows |
Database User Requirements
The PostgreSQL user provided to OpenHands Enterprise needs specific privileges depending on your preferred setup approach.Option 1: Automatic Database Creation (Recommended)
If you provide a database user with theCREATEDB privilege, OpenHands Enterprise will
automatically create all required databases during installation.
public schema.
Option 2: Manual Database Creation
If your security policies prevent grantingCREATEDB, you must manually create all
databases before installation:
Network Requirements
Ensure your PostgreSQL instance is accessible from:- The OpenHands application pods/services
- The Keycloak service
- The LiteLLM proxy service
- The Runtime API service
Configuration
When configuring OpenHands Enterprise, provide your external PostgreSQL connection details in the Admin Console or Helm values:- Host: Your PostgreSQL server hostname or IP
- Port: PostgreSQL port (default: 5432)
- Username: The database user created above
- Password: The user’s password
For production deployments, we recommend enabling SSL/TLS for database connections.

