Skip to content
MtrXTools

Unable to negotiate with 203.0.113.10 port 22: no matching key exchange method found. Their offer: diffie-hellman-group1-sha1

Client and server share no key exchange algorithm

Seen in OpenSSH client connecting to old servers, routers, switches and embedded devices

The server only offers key exchange algorithms that your SSH client has disabled as weak.

Common causes

  • The device or server is old and only supports diffie-hellman-group1-sha1 or group14-sha1.
  • The client or server has a hardened KexAlgorithms list with no overlap.

How to fix it

  1. Upgrade the server firmware or OpenSSH so it supports a modern algorithm (curve25519-sha256).
  2. As a per-host workaround, enable exactly what it offers: ssh -o KexAlgorithms=+diffie-hellman-group14-sha1 user@host, or the same line under a Host block.
  3. Avoid adding weak algorithms globally in ssh_config.

Got a different message? Paste it into the error explainer.

Related errors

All 31 Dev tools & SSH errors