App overview screenshotSQL and Database Guides
PostgresMySQLSQLite
Try our free SQL Client
Tools
Connecting to Postgres
Connecting to Drivers
Installing Postgres
Setting up Postgres
Postgres   >   
Connecting to Postgres   >   
Postgres SQL Client

Learn How To Connect to PostgreSQL from a SQL Client

If you are working with a PostgreSQL database as part of your project, you’ll probably need to add or edit data. We recommend using an SQL client to do so. In this guide, we’ll walk you through how to connect to your Postgres database using an SQL client.

What You’ll Need

Getting your PostgreSQL Credentials

In order to connect to your database, you’ll need to get your Postgres credentials. These include:

  • Host/IP: If you’re running a local PostgreSQL server, this will likely be localhost or 127.0.0.1. If your Postgres database is not hosted on your local network, you’ll need the public ip address/hostname of the server on which it is hosted. One way to do this is to run SELECT inet_server_addr() from your Postgres server’s command line
  • Port: This will almost always be 5432 (default). You can check by running SELECT * FROM pg_settings WHERE name = ‘port’
  • Database: You’ll need the name of the database schema on your server that contains your data.
  • User and Password: You’ll need credentials for a user with privileges on your database schema.

Connecting to your PostgreSQL Database

For this guide, we’ll be using Arctype, where you can simply click Add a new data source or Add connection and choose ‘PostgreSQL’ to begin:

Arctype add connection button

Next, enter the credentials we gathered above:

Successful connection

Once you’re connected, you can easily interact with your PostgreSQL data:

Arctype table view

Get help on databases and SQL. Join our Discord community.