Connection guide

Connect Fly.io Postgres to Dora

Fly Postgres runs in a private network. You need to forward the port to localhost first — here is the one-command way to do it.

Fly Postgres instances live inside Fly's private network and are not reachable from the public internet by default. To connect from the Dora desktop app on your machine, you forward the Fly port to localhost using the Fly CLI. This is a Fly networking constraint, not a Dora limitation.

Once the port is forwarded, Dora connects to it exactly like any other local Postgres — paste the connection string with localhost as the host and you are done.

PostgreSQL connection string

postgresql://postgres:[PASSWORD]@localhost:5432/[DBNAME]

Steps

  1. 1.Install the Fly CLI and authenticate

    Install flyctl from fly.io/docs/hands-on/install-flyctl and run fly auth login if you have not already.

  2. 2.Forward the Postgres port to localhost

    Run: fly proxy 5432 -a [your-postgres-app-name] This forwards Fly port 5432 to localhost:5432 on your machine. Keep the terminal open while you use Dora.

  3. 3.Get the database credentials

    Run: fly postgres connect -a [your-postgres-app-name] — this prints the DATABASE_URL. Note the password and database name from it.

  4. 4.Add a connection in Dora

    Create a new Postgres connection in Dora with host localhost, port 5432, and the credentials from the previous step. Or paste the full connection string with localhost substituted as the host.

  5. 5.Test and connect

    Click Test (with fly proxy still running in the terminal), then Connect. Your Fly Postgres tables load into the sidebar.

Good to know

  • fly proxy must be running in a terminal for the duration of your Dora session. Closing it drops the connection — this is a Fly networking requirement.
  • If you are on a machine connected to Fly via WireGuard, you can use the .internal or .flycast address directly without fly proxy.
  • For production databases, fly proxy is safer than opening public ports — it forwards traffic through an authenticated SSH channel.