Skip to main content

Install Postgres and psql on Mac

Published: 2019-10-11

  1. Download and install Postgres.app

  2. Set environment variables in your bash config file, e.g. ~/.bash_profile

     export POSTGRES_HOME=/Applications/Postgres.app/Contents/Versions/latest
     export PATH=$POSTGRES_HOME/bin:$PATH
    
  3. Source bash config file

     source ~/.bash_profile
    
  4. Confirm installation

     psql --version
    

Next: Show hidden files in Mac Finder by default
Previous: Log docker stats to a file