Basically, follow the steps as outlined here: https://wiki.postgresql.org/wiki/Apt.
sudo apt-get install curl ca-certificates gnupg
curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
sudo apt-get update
sudo apt-get install pgadmin4
(The actual command for the last step includes
postgresql-11. I never do that because I just want
pgadmin4 and have never had issues with it working properly.)
Reading package lists... Done Building dependency tree Reading state information... Done Package pgadmin4 is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'pgadmin4' has no installation candidate
I did also try to do the following, but it requires
python3.7 which I'm not going to install.
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt eoan-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
focal shows up at