The default database of ZITADEL is CockroachDB. The SQL database provides a bunch of features like horizontal scalability, data regionality and many more.
The default configuration of the database looks like this:
PostgreSQL extension is currently in Beta. Beta state will be removed as soon as automated tests are implemented. Github Issue
Be aware that PostgreSQL is only Enterprise Supported.
If you want to use a PostgreSQL database instead of CockroachDB you can overwrite the default configuration. Make sure to read our Production Guide before you decide to use it.
Currently versions >= 14 are supported.
Postgres can be configured as follows:
The admin user is only needed for the installation step but can also be avoided by preparing the necessary requirements:
- the zitadel user
- the zitadel database
- granting required permissions to the zitadel user
CREATE ROLE zitadel LOGIN;
CREATE DATABASE zitadel;
GRANT CONNECT, CREATE ON DATABASE zitadel TO zitadel;
Don't forget to adjust pg_hba.conf and set a password for the zitadel user.
With the setup done, follow the phases guide to run the init and then setup phase to get all necessary tables and data set up.