Windows operating system, including Windows Vista, Windows 7 and Windows Server, is designed in a way that the last user who logged into the system is remembered, and is displayed automatically on next log in, so that user has to just enter the password to log on. In the Welcome Screen, user account names are listed, or in the case of only single account available, automatically selected to prompt for password. In classic Windows logon box (including the Logon to Windows box after press Ctrl + Alt + Delete shortcut), the user name who logged in most recently is displayed as user name to log on.

The behavior to remember and display the last user name who logged in to the Windows system most recently is built into Windows operating system to allow user to login quickly by just entering password. However, some users may not like the feature as it will give away the identity of user who used the computer. In addition, on common shared PC, there will be additional steps to delete, remove and clear the user name before entering the correct own user ID. User who forgotten to change the user ID on display can accidentally lock other user out if trying too many incorrect password.

Windows provides a registry or group policy trick that instruct Windows not to remember and display the last user name who logged in. Follow the steps below to tweak the registry setting or group policy:

  1. Run Registry Editor (RegEdit).
  2. Navigate to the following registry key:

    HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\System

  3. In the right pane, double click on DontDisplayLastName registry key value, and set its value data to 1.

    Don't Display Last User name

Alternatively, the registry key above can be changed and modified via Local Security Policy Editor, as shown in guide below.

  1. Click on Start button, and type secpol.msc into Start Search box, and hit Enter to open the Local Security Policy Editor.
  2. Navigate to Security Settings -> Local Policies -> Security Options.
  3. In the right pane, double click on Interactive Logon: Do not display last user name.
  4. Select and set the radio button of Enabled.

    Enable Do Not Display Name of Last Logged In User Policy

  5. Click Apply or OK.

Once enabled, the name of the last user to successfully log on is not displayed in the Logon Screen.