reminder: logging into postgres with shell commands



~1 min read


91 words

PGAdmin, Dbeaver, etc. are useful GUIs for managing and reviewing Postgres databases. Sometimes, however, there’s a desire to login via the CLI.

Every time I have this happen, I need to look it up again - so, I’m writing it down to hopefully make that search shorter in the future: -U <your username.

Note, I’m using psql here - which is a “terminal-based front-end to Postgres.”1


  • 1 For more about psql, see the manual page in your terminal with man psql

Hi there and thanks for reading! My name's Stephen. I live in Chicago with my wife, Kate, and dog, Finn. Want more? See about and get in touch!