FTPMonitor / Guides / SFTP host key verification failed

SFTP host key verification failed

Why SSH host key verification fails and how to resolve known_hosts conflicts.

Diagnose this automatically

Verify whether authentication is the actual failure point.

terminal
npx ftpmonitor check --protocol sftp --host sftp.example.com --port 22 --username user --password pass
Shareable output
terminal
npx ftpmonitor check --protocol sftp --host sftp.example.com --port 22 --username user --password pass --format slack --copy

Prefer the browser? Run the same check on the homepage.

Host key verification errors occur when the server's SSH key does not match the client's known_hosts entry.

Common causes

  • Server host key changed
  • Man-in-the-middle protection triggered
  • Old known_hosts entry

Fix checklist

  1. Verify the new host key with the server administrator.
  2. Remove the old entry from ~/.ssh/known_hosts.
  3. Reconnect to store the updated host key.
Related
Diagnostics powered by FTPMonitor CLI