Connect your local database

Connect your local PostgreSQL database to Flashboard in a few steps. You'll be managing your data in minutes.

Prerequisites

Before you start, make sure you have:

  • Node.js installed on your machine
  • PostgreSQL running locally with SSL enabled

If your PostgreSQL server doesn't have SSL enabled, follow our guide first: Enabling SSL on your local database.

Step 1: Start the Flashboard CLI

Open your terminal and run:

npx flashboard@latest local

The first time you run this command, it will ask you to sign in to your Flashboard account. After signing in, the CLI creates a secure tunnel to your machine and keeps it open.

You'll see a message confirming the connection is active. Keep this terminal window open while you work with your local database.

Step 2: Create a panel with your local connection

Go to Flashboard and create a new panel. When asked for the connection string, use your local PostgreSQL URL:

postgres://username:password@localhost:5432/your_database

Read our PostgreSQL integration docs for instructions on how to build your connection URL.

Flashboard recognizes localhost and 127.0.0.1 as local connections and routes them through the secure tunnel.

Step 3: Verify the connection

Once connected, you'll see your database tables in Flashboard. A green indicator in the header shows that the local connection is active.

If you close the CLI, the connection indicator turns gray and queries to your local database will fail. Just run npx flashboard@latest local again to reconnect.

Troubleshooting

"SSL connection failed" error

Your PostgreSQL server needs SSL enabled for local connections. Follow our guide: Enabling SSL on your local database.

"Local Flashboard connection is not active" error

The Flashboard CLI isn't running. Open a terminal and run:

npx flashboard@latest local

Connection times out

Make sure PostgreSQL is running and accepting connections on the port specified in your connection string (default is 5432). You can test this with:

psql "postgres://username:password@localhost:5432/your_database?sslmode=require"

Wrong credentials

Double-check your PostgreSQL username and password. If you're using the default PostgreSQL installation, the username is often postgres.

Felipe Freitag, Flashboard founder

Need help?

Hey! I'm Felipe, Flashboard's founder. I'll personally help you and make sure you get your panel up and running.

We use optional cookies to measure advertising performance. Learn more