Skip to content

Share Postgres data without sharing credentials

A teammate often needs to see rows in your Postgres database, or to update a few of them. A common first step is to send a connection string, or to create a database login and share the password.

That login can run SQL. It can also open other tools that use the same string. If the person should see only some tables, or only some rows, a shared login is hard to keep tight.

OnlyDash gives the teammate an admin panel instead. You paste one connection string. Then you invite the person and choose the tables and rows they can open. Teammates do not get the connection string. After you save it, nobody sees the password, not even you.

Why people share a connection string

A connection string has the host, the database name, the user and the password. Anyone who has it can connect with psql, a SQL client or an app. The rights of that session come from the database role, not from the tool they pick.

You can reduce the risk in Postgres. Create a role that can only read, or only write, the tables that person needs. Grant those rights with GRANT. Revoke rights on the other tables. This is standard PostgreSQL access control.

Those grants still apply to a SQL session. A person who can run SQL can select more rows than you meant, if a grant is too wide. They can also export the result. A grant does not give them a form, a filtered grid or a simple way to work on a phone.

A read-only database role can connect to OnlyDash. OnlyDash checks what that role can write on each table. If the role only has SELECT, OnlyDash hides the write controls and blocks writes. If the role can write nothing, the whole panel is read-only. You can also use the Viewer role in OnlyDash on a read-write role.

What you can do in Postgres

You can also hide columns behind a view, and grant access only to that view. OnlyDash reads base tables. It does not show views or materialized views in the panel, so that pattern does not carry over to the panel.

For row limits inside the database, Postgres has row-level security. Policies run in the database for every session, except for roles that bypass them. See Postgres row-level security for an admin panel. OnlyDash does not use row-level security as its filter method.

Hosts such as Amazon RDS, Google Cloud SQL, Neon and Supabase work when OnlyDash can reach the host. Neon and Supabase pooler URLs work too. See Neon Postgres admin panel and Supabase admin panel if that is your host.

How OnlyDash shares the data

Paste a Postgres connection string. OnlyDash tests the connection, then reads the base tables, columns, primary keys, foreign keys and enums. It samples up to 1,000 rows per table. Each table gets a grid with filters, sort and pagination, plus forms to create and edit rows.

Related records show on the edit pane, from your foreign keys. Forms follow the column type, with pickers for enums. Search the tables you can see with Cmd-K. OnlyDash also makes charts for each table when it reads your data. The charts show above the table. An empty table says "No data to chart yet."

You stay the owner of the connection. Invite a teammate with the Viewer or Editor role, or with a Custom rule. A Custom rule sets each table to view, edit or hidden. A hidden table does not open for that member. You can also set a row filter, so they see only matching rows.

OnlyDash applies that filter on the server. The filter applies to the table, charts, search, exports and edits. A Viewer cannot edit. An Editor can change or add rows only inside the filter. Export the rows you can see as a CSV file. Edits go to your database. OnlyDash does not keep a full copy of your tables. It stores the connection string, schema facts, sample statistics, and the old and new values of fields that people change in the panel.

Activity history records each write that goes through the panel. The record shows who made the change, the table, the action, the row, and the old and new values. You can open the history for one row, or export the activity as CSV. Edits made directly in your database, outside OnlyDash, are not in the history.

Guests can connect a Postgres database without signing up. OnlyDash is in beta.

Pick a person to see their view

Owner sees 17 of 17 rows

No row filter.

invoices, as Owner sees it
StatusAmountDue dateIssued datePaid date
Unpaid5,000.00Jul 1Jun 1
Paid7,500.00Aug 1Jul 1Jul 15
Paid24,000.00May 1Apr 1Apr 24
Paid31,500.00Jul 1Jun 1Jun 19
Paid42,000.00Jun 1May 1May 28
Paid18,500.00Apr 1Mar 1Mar 21
Paid12,750.00May 1Apr 1Apr 15
Paid9,800.00Jun 1May 1May 9
Unpaid27,300.00Sep 1Aug 1
Unpaid33,900.00Sep 1Aug 1
Unpaid15,600.00Aug 1Jul 1
Unpaid21,400.00Sep 1Aug 1
Overdue8,900.00Jun 1May 1
Overdue46,200.00Jul 1Jun 1
Overdue5,400.00May 1Apr 1
Draft19,750.00Oct 1Aug 1
Draft6,300.00Oct 1Aug 1

Swipe to see more.

Sample rows from the invoices table in the Sample project database, the guest demo on OnlyDash. The demo shows what each person gets after you invite them.

Connect your Postgres database

Paste a connection string, or try the demo with no sign-up. OnlyDash is in beta.

Try the demo, no sign-upConnect your database

Set up access without handing over the string

  1. Open the Postgres admin panel and paste your connection string.
  2. Invite each teammate and choose Viewer, Editor or Custom.
  3. Hide the tables they should not open, and set a row filter if they should see only some rows.

Use a stable column for the filter, such as a team name or the person's email. The value can be a fixed value or the member's own email.

For a client who should see only their rows, see Give clients only their rows in Postgres.

Questions

Do teammates get the connection string?

No. They open the OnlyDash panel. Teammates do not get the connection string. After you save it, nobody sees the password, not even you. You choose the tables and rows they can open.

Can I share Postgres data without a new database login for each person?

Yes. Paste one connection string. Then invite each person and set their role, tables and row filter in OnlyDash.

Does OnlyDash keep a copy of my tables?

No. OnlyDash does not keep a full copy of your tables. It stores the connection string, schema facts, sample statistics, and the old and new values of fields changed in the panel.

Can a person connect without signing up?

Yes. Guests can connect a Postgres database without signing up. You can also try the demo with no sign-up.

Connect your Postgres database

Paste a connection string, or try the demo with no sign-up. OnlyDash is in beta.

Try the demo, no sign-upConnect your database

For a product overview, see the Postgres admin panel.