The first step is to create a key pair on the client machine (usually your computer):
ssh-keygen
output will be something like Output Generating public/private rsa key pair. Enter file in which to save the key (/your_home/.ssh/id_rsa): that is the location where the stored Next step will be
ssh-copy-id username@remote_host
and password will be asked, insert password and you are good to go.