SSH keys and GitHub

Test your SSH connection to GitHub

Check your SSH key works with GitHub, and what each answer means.

  1. Test it
    Terminal
    ssh -T git@github.com

    Type yes if asked. "Hi username! You've successfully authenticated" means it works. "Permission denied (publickey)" means GitHub doesn't know your key yet.

  2. See the full conversation if it fails
    Terminal
    ssh -vT git@github.com

    Look for "Offering public key" lines to see which keys were tried.

  1. Test it
    Terminal · Ubuntu / Debian
    ssh -T git@github.com

    Type yes if asked. "Hi username! You've successfully authenticated" means it works. "Permission denied (publickey)" means GitHub doesn't know your key yet.

  2. See the full conversation if it fails
    Terminal · Ubuntu / Debian
    ssh -vT git@github.com

    Look for "Offering public key" lines to see which keys were tried.

  1. Test it
    PowerShell
    ssh -T git@github.com

    Type yes if asked. "Hi username! You've successfully authenticated" means it works. "Permission denied (publickey)" means GitHub doesn't know your key yet.

  2. See the full conversation if it fails
    PowerShell
    ssh -vT git@github.com

    Look for "Offering public key" lines to see which keys were tried.