What causes this error?
When you paste an SSH key into the Compute dashboard and see “Invalid SSH key,” it usually means:- You pasted the private key instead of the public key
- You copied only part of the public key or included extra spaces/line breaks
- Your key type isn’t recognized (e.g., an unsupported format)
1
Verify you’re using the public key
- Open your
.ssh
folder - Find the file ending in
.pub
(for example,id_ed25519.pub
orid_rsa.pub
). - Right‑click the
.pub
file → Open with → Notepad. - Select and copy the entire single line, starting with
ssh-ed25519
orssh-rsa
and ending with your email or comment.
Don’t open or copy the file without
.pub
. That’s your private key!2
Regenerate your key if needed
If you can’t find a
.pub
file or suspect it’s corrupted, create a fresh pair:- Accept the default file location or give it a custom name (e.g.,
id_hivenet
). - When prompted, set a passphrase (optional but adds security).
.pub
file.3
Paste carefully into the dashboard
- In the Compute dashboard, go to Add SSH key.
- Click inside the SSH key field—avoid pasting into any other box.
- Paste your copied public key in one go (Ctrl+V).
- Click Save or Add key.
If you see line breaks or extra spaces, click inside the field and use backspace or delete.
Common pitfalls
Hidden newline characters: Some editors add a newline at the end. Make sure the pasted text ends with your key comment, not an empty line. **Wrong key type: **Compute supportsssh-ed25519
and ssh-rsa
. ECDSA keys may not work.
**Mixing up accounts: **If you have multiple keys, verify you copied the one linked to the current Compute account.