Connecting to PostgreSQL lets you reverse engineer PostgreSQL to an ERD in seconds. Schemity reads your tables, columns, primary and foreign keys, unique constraints, indexes, and check constraints, then draws the whole schema.

Open the connection form

Choose New connection, set DB type to PostgreSQL, and set Conn method to Direct connection (or SSH Tunnel to reach a database behind a bastion).

Database configuration fields

  • Host and Port - the server address and port. Port defaults to 5432.
  • Username - the role Schemity authenticates as. A read-only role is recommended for documentation.
  • Password - the role’s password. It is stored in your OS keychain, never in the JSON file. Leave it blank when editing to keep the existing one.
  • DB name - the database to introspect.
  • Schema - the schema to read. Defaults to public.
  • Encryption - either Disable (local dev only) or Require (recommended). Use Require for any managed or cloud-hosted Postgres.

If you chose SSH Tunnel, an extra block asks for the SSH host, port (default 22), username, password, and an optional SSH key file.

Reverse-engineer the schema

Once connected, Schemity imports every table in the target schema - there is no table-picking step. It reads tables and columns with their PostgreSQL types, primary keys and nullability, foreign keys (with their ON DELETE / ON UPDATE actions) drawn as crow’s foot relationships, unique constraints, indexes, and check constraints.

Supabase and managed Postgres

Schemity works as a Supabase schema diagram tool and with any managed Postgres: use the host, port, and Require encryption your provider gives you. Everything renders locally, so you get a private picture of a cloud database without uploading anything.

Next

Save the diagram to Git (see Version Control in Git), or tidy the layout on The ERD Canvas.