SSH key types
SSH key types
ED25519 and RSA are the most common SSH key algorithms. Use ED25519 unless you need legacy compatibility.
RSA (ssh-rsa)
RSA is one of the oldest and most widely supported SSH key algorithms. It remains compatible with virtually all SSH servers and clients.
Advantages
- Excellent compatibility with older systems.
- Supported by almost every SSH implementation.
- Good choice when connecting to legacy servers.
Considerations
- Larger key sizes are recommended (at least 3072 or 4096 bits).
- Slower than newer algorithms.
- Larger public and private keys.
ED25519 (ssh-ed25519)
ED25519 is a modern elliptic-curve algorithm designed to provide strong security with smaller keys and faster authentication.
Advantages
- Smaller key size.
- Faster authentication.
- Strong modern cryptography.
- Recommended for most new deployments.
Considerations
- Very old SSH clients and servers may not support ED25519.
Choose an algorithm
For most users, ED25519 is the recommended choice due to its excellent security and performance.
Choose RSA only if you require compatibility with older systems or legacy SSH software.