Skip to content

Connecting

Every database exposes two connection URLs. Use the one that matches where you’re connecting from.

URLWhen to use it
InternalFrom other Runsite services in the same project. Traffic never leaves the private network — lowest latency, no public exposure.
ExternalFrom your laptop, third-party tools, or anything running outside Runsite. Encrypted with TLS.

Both are standard PostgreSQL connection strings. You’ll find them on the database’s Overview tab — copy them directly, don’t construct them by hand.

A real internal URL looks like:

postgresql://test_user:GJRf~r2sTma4umuN~vE6oGWz@dpg-ximnyfiir4kw742sc8cv-rw:5432/test

A real external URL looks like:

postgresql://test_user:GJRf~r2sTma4umuN~vE6oGWz@dpg-ximnyfiir4kw742sc8cv.eu-central-postgres.runsite.app/test

Notice:

  • The internal host (dpg-...-rw) is short and only resolves inside Runsite. The -rw part points to the read-write primary.
  • The external host adds the region and base domain (eu-central-postgres.runsite.app).
  • The internal URL keeps the explicit :5432. The external URL omits it — clients use the standard Postgres port by default.
  • Username and database name come from what you set when creating the database.

Inside another Runsite service in the same project, use the internal URL. Add it as an environment variable in the service’s Environment tab:

Terminal window
DATABASE_URL=postgresql://test_user:GJRf~r2sTma4umuN~vE6oGWz@dpg-ximnyfiir4kw742sc8cv-rw:5432/test

Your app reads DATABASE_URL like any other Postgres host — no special client needed.

Use the external URL with the psql CLI:

Terminal window
psql "postgresql://test_user:GJRf~r2sTma4umuN~vE6oGWz@dpg-ximnyfiir4kw742sc8cv.eu-central-postgres.runsite.app/test"

Or paste it into your favourite client (DBeaver, TablePlus, DataGrip, pgAdmin) — they all accept this URL format.

The password is shown once, when you create the database. After that the dashboard masks it. Save it in a password manager or in your service’s environment variables right away.

If you lose the password, you can reset it from the database settings.