# For quick install
pip install psycopg2-binary
# For production-ready install
pip install psycopg2
# But it will fail if build prerequesties are not met:
# https://www.psycopg.org/docs/install.html#build-prerequisites
pip install psycopg2
#Use psycopg2-binary instead of psycopg2.
pip install psycopg2-binary