Repeated SSH connections often use the same account on a server. PuTTY can save a default username in a session profile so it sends that name without another login as: prompt.

PuTTY stores connection options as a session profile, including the Auto-login username field under Connection → Data. When the session opens, PuTTY sends that username during the SSH authentication handshake before continuing with password, key-based, or keyboard-interactive prompts.

The username identifies an existing account on the SSH server; it does not save a password or grant access to that account. Password or key authentication is still required for a successful login. An incorrect username can cause repeated authentication failures that may trigger account lockouts or IP bans on hardened servers.

Steps to set a default username in PuTTY:

  1. Select the existing session under Saved Sessions in PuTTY Configuration if updating a saved connection.

    For a new connection, skip this selection and the next Load step.

  2. Click Load for the selected saved connection.

    Loading restores the profile's saved options, replacing unsaved edits in the window; it belongs before any changes.

  3. Enter the SSH server's address in Host Name (or IP address) under Session.

    A loaded profile can keep its existing address.

  4. Set Port to the server's SSH port.

    The usual SSH port is 22; a server configured for another port needs that value instead.

  5. Select Data under Connection in the category tree.
  6. Enter the server account name in Auto-login username.

    An account name such as abc may differ from your Windows username.

  7. Select Session in the category tree.
  8. Enter a profile name in Saved Sessions.

    A name such as My server identifies the connection; an updated profile can keep its loaded name.

    Saving under an existing name replaces that profile's settings immediately. A different name preserves the original profile.

    Saving over the selected Default Settings entry changes the initial options for new connections; existing named sessions retain their own settings.

  9. Click Save to store the username with the session.
  10. Close PuTTY Configuration.
  11. Reopen PuTTY.
  12. Select the saved profile under Saved Sessions.
  13. Click Load to restore the saved profile.
  14. Select Data under Connection.
  15. Confirm that Auto-login username still contains the account name you saved.

    A blank or different value means the intended username was not saved in the profile you loaded.

    An unverified host key can send your connection to an impostor. If a host-key alert appears, its fingerprint must match a reference from the server administrator or another trusted channel before continuing.

  16. Click Open to connect with the loaded profile.
  17. Confirm that the terminal's Using username line names the saved account without a login as: prompt.

    The pictured Using username "abc". confirms the selected username was used. The accompanying No supported authentication methods available (server sent: publickey) error means account authentication failed because a suitable key was unavailable; it does not mean a login succeeded. A password prompt or key authentication may follow on a server that accepts your account's credentials.

Share this guide