As long as you use strong passwords, it is not necessary to disable SSH password authentication for your server; however, you can disable it if you would like.
Before you proceed, keep these things in mind:
To disable SSH password authentication, SSH in to your server as root to edit this file:
Then, change the line
After making that change, restart the SSH service by running the following command as root:
sudo service ssh restart