Using SSH Key Make sure SSH key is added to GitLab. Create config file for using the generated SSH key. ~/.ssh.config# GitLab.com Host gitlab.com PreferredAuthentications publickey IdentityFile ~/.ssh/id_ed25519 Ensure Git Username and Email are configured and proceed to using Git as usual.