Connect to Heroku Postgres from Mac
Use the current credentials for the Heroku Postgres database attached to your application. A database credential includes its own host, port, database, user, and password.
Before you start
Section titled “Before you start”You need access to the database’s credentials and a permitted external connection route. Your Heroku account password is separate from the database password.
Find your connection details
Section titled “Find your connection details”Obtain a current PostgreSQL connection URL for the intended database and credential. Follow Heroku’s credential guide for the current controls. A named credential can provide narrower permissions than the owner account.
Keep the URL private because it contains the database password.
Connect to Heroku Postgres from Mac
Section titled “Connect to Heroku Postgres from Mac”- Open a new connection using connection basics.
- Use Import from URL to import the database URL.
- Check the imported host, port, database, and user.
- Set SSL Mode for your Heroku database.
- Click Test.
- Click Save & Connect after a successful test.
SSL and private databases
Section titled “SSL and private databases”Heroku requires SSL for database client connections. Use the certificate requirements for your database with TableAI’s SSL/TLS controls. See Heroku’s SSL requirement.
Private and Shield databases have separate external-access requirements. Follow Heroku’s external connection guide for approved access and client certificates.
If it does not connect
Section titled “If it does not connect”password authentication failed for userno pg_hba.conf entry for hostAfter a credential rotation, obtain fresh details and update the saved connection.
Check every field, since credentials identify more than a password.
If the error ends in SSL off, check your SSL configuration.
See Heroku’s error reference.
Continue with 28P01, TLS errors, or connection failed.
Related
Section titled “Related”Browse and search after connecting, or return to the PostgreSQL overview.