12

My wife doesn't use a password on her account so when I boot into Windows 11, I always have to log out of her account first because it logs her in automatically. How can I disable that without giving her a password?

11
  • 5
    Do you see the Users must enter a user name and password to use this computer. checkbox? You should enable it. Your system has a user, defined as the default user, when your system boots the user is automatically logged in. By indicating the user must supply a password, that user will have to enter a password, in the case of a user without a password it's a blank password.
    – Ramhound
    Commented Feb 25, 2022 at 20:19
  • 2
    Same issue is annoying me. None of the solutions here do what I'm after. Did you ever figure this out? Commented Sep 7, 2023 at 9:36
  • 2
    @MilesHayler: Unfortunately not. Commented Sep 7, 2023 at 11:30
  • 2
    This "solution" does not work at all, option is being ignored.
    – Vortilion
    Commented Sep 11, 2023 at 15:18
  • 1
    This question is similar to: netplwiz not updating account username. If you believe it’s different, please edit the question, make it clear how it’s different and/or how the answers on that question are not helpful for your problem.
    – Ramhound
    Commented Jul 21 at 19:28

6 Answers 6

4

I just had a similar issue in Windows 11. As Ramhound wrote in a comment, you just need enable Users must enter a user name and password to use this computer after running netplwiz. However, this checkbox can be missing (as mentioned here).

To get the checkbox back, set DevicePasswordLessBuildVersion to 0 in registry branch HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device

0
3

I was finally able to stop this behavior in Windows 11 Pro 23H2 by using Group Policy Editor (gpedit.msc):

  1. Navigate to Local Computer PolicyComputer ConfigurationAdministrative TemplatesWindows ComponentsWindows Logon Options

  2. Double-click Sign-in and lock last interactive user automatically after a restart

  3. Change the setting to Disabled:

    enter image description here

  4. Click OK to apply the change

Extra digging

For the curious (and benefit of anyone with Windows 11 Home), I used Process Monitor to see what's actually going on behind the scenes with this policy and it appears that it sets the following registry key's value to 1:

HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System\DisableAutomaticRestartSignOn
2

Auto-login can be set in the registry. If that's your case, you may remove it like this:

  • Run regedit
  • Position to the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon
  • Right-click the following items and select "Delete": AutoAdminLogon, DefaultUserName, DefaultPassword
  • Logout/login or reboot to test.
2
  • 3
    I don't have those keys, and yet this still happens. I do have "AutoLogonSID", which is suspicious
    – rkj
    Commented Nov 11, 2023 at 2:54
  • @rkj - You don't have those keys because you did not configure a default user. Once you uncheck Users must enter a user name and password to use this computer, the appropriate keys will be created, after the prompt is displayed.
    – Ramhound
    Commented Jul 21 at 19:36
0
  1. Open Netplwiz:

    • Press Windows Key + R to open the Run dialog.
    • Type netplwiz and press Enter.
  2. User Accounts:

    • In the "User Accounts" window, you'll see a list of all user accounts on your PC.
    • Click on the user account for which you want to disable auto-login.
  3. Uncheck the Option:

    • At the top of the window, you'll see an option labeled "Users must enter a user name and password to use this computer." Make sure this box is checked.
  4. Apply and Close:

    • Click Apply and then OK.
  5. *Restart your Computer

0
-1

This is a stub, but maybe someone can find it useful.

One issue here is that Windows 11 remembers the last logged on user, and will automatically go to that account after startup (and will log in if no password is set).

Last user is saved in the registry, at key:

Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI

Last logged on user can be cleared with the following .bat file, which I've found in this thread and I have verified works in Windows 11 when run as administrator.

reg delete HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI /v LastLoggedOnUser /f
reg delete HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI /v LastLoggedOnUserSID /f
reg add HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI /v LastLoggedOnUser
reg add HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI /v LastLoggedOnUserSID
echo last logged on user has been cleared
pause
exit

So, one would need to find a way to run such a script after the user without password has logged out, and before the machine shuts down: At next startup, Windows will provide a screen from which to choose the user for logon.

1
  • This could work but you would have to run the script every time. It might be worth considering if it was really the only option, but it's not.
    – Shifty
    Commented Jul 22 at 20:49
-2

Disable auto login for Windows10 and 11 with this simple steps.

  1. go to settings> Accounts.
  2. On the left side of the window you will find Sign In Options.
  3. Click on Sign in options and you will find "If you’ve been away, when should Windows require you to sign in again" Toggle When PC wakes up from sleep. You can try other alternatives if you are using a older version of Windows.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .