Windows OS Hub
  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu
  • Home
  • About

Windows OS Hub

  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu

 Windows OS Hub / Windows 10 / How to Enable Windows Auto Login without a Password

September 22, 2023 Windows 10Windows 11Windows Server 2019

How to Enable Windows Auto Login without a Password

A user must enter a password for a local or Microsoft (online) account each time they log on to Windows. This allows you to restrict access to your computer. In this article, we will look at how to disable the password prompt on the logon screen in Windows 10/11 and allow automatic login to the computer using specific user credentials. Auto-logon assumes that user credentials (username and password) are stored in the Windows registry and used for automatic login.

Contents:
  • How to Disable Login Password on Windows
  • Enable Windows Auto Login via the Registry
  • Disable Password After Resuming from Sleep/Hibernation on Windows
  • Enable Auto Sign-in to Windows with the AutoLogon Tool

Warning. Automatic login to Windows is a convenience for the user, but it is a compromise to the security of your computer. You should only use Autologon if you are the only person who has access to the computer.

Disabling the Windows logon password does not mean that your account should have a blank password. Windows can use saved user credentials (name and password) to automatically logon to the computer. In all other cases, for example, when accessing from another computer over the network (SMB) or when connecting to a Remote Desktop (RDP), you will be prompted for a password.

disable password login screen on windows 10

How to Disable Login Password on Windows

On a standalone computer and in a workgroup environment, the easiest way to turn off the logon password prompt on the Windows sign-in screen is to use the User Accounts Control Panel.

  1. Press Win+R and run the command netplwiz or control userpasswords2 ;netplwiz
  2. A list of local Windows accounts will appear. Uncheck the option “User must enter a username and password to use this computer” and save changes (OK);   turn off password login on windows 10 - User must enter a username and password to use this computer
    Starting with Windows 10 20H1, the option “User must enter a username and password to use this computer”  is not shown by default if you use a local user account to sign-in Windows instead of a Microsoft cloud account (MSA). Create the DevicePasswordLessBuildVersion registry value with a value of 0 in the HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device key to display this check box.
    You can make changes to the registry using PowerShell:New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" -Name DevicePasswordLessBuildVersion -Value 0 -Type Dword –ForceThis will disable the “Require Windows Hello sign-in for Microsoft accounts” option. Re-open the netplwiz console and make sure that the checkbox has appeared. windows 10 20H2 Netplwiz no longer has auto-login option
  3. Enter the user name and password (twice) for the account you want to use to automatically log on to Windows; set user credentials to automatically login windows
  4. Restart your computer and make sure that the Windows boots directly to the desktop without entering a password.
     The AutoLogonSID registry parameter in the HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon key stores the user SID used to log on.

On computers that have been added to an Active Directory domain, you cannot turn off the “Require username and password” option because of the domain password policy. In this case, you can enable Windows autologin via the registry (see below).

Enable Windows Auto Login via the Registry

You can save a user password in the computer’s registry to allow Windows to log on automatically. This allows you to set up automatic logon without prompting for a password and to skip the Login Screen for your Microsoft account, domain account, or local account.

Warning. This autologin method is not secure, as the user’s password is stored in plain text in the registry and can be viewed by any local user.
  1. Press Win+R and type regedit;
  2. Go to the registry key HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon;
  3. Change the value of the registry parameter AutoAdminLogon from 0 to 1;
  4. Create a new string parameter DefaultDomainName and specify the domain or a local computer name as its value;
    Tip. You can find out your current computer name using the  hostname command.hostname
  5. In the DefaultUserName parameter you need to specify the user account name you want to sign in with;
  6. Specify the user account password in plain text in a string reg parameter DefaultPassword (create if missing);AutoAdminLogon registry
  7. Close the Registry Editor and restart your computer;
  8. When Windows boots, it should automatically log on using the saved user name and password, without prompting for user credentials on the logon screen.

You can enable Windows autologin via the registry using the following BAT script.  Replace root and P@ssword with your username and password, and replace WORKGROUP with the name of your AD domain (if the domain user account is used).

reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v AutoAdminLogon /t REG_SZ /d 1 /f
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v DefaultUserName /t REG_SZ /d root /f
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v DefaultPassword /t REG_SZ /d P@ssword /f
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v ForceAutoLogon /t REG_SZ /d 1 /f
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v DefaultDomainName /t REG_SZ /d WORKGROUP /f
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v IgnoreShiftOvveride /t REG_SZ /d 1 /f

If the automatic login is not working, you may need to remove the AutoLogonChecked and AutoLogonCount registry items.

reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v AutoLogonCount /f
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v AutoLogonChecked /f

The AutoLogonCount contains the number of times you can log Windows in using the automatic logon feature. This value decreases each time the computer boots.  If the value reaches 0, the automatic login is disabled.

Or you can run a PowerShell script to write the user’s logon credentials to the registry:

$Username ='max'
$Pass = 'Max$uperP@ss'
$RegistryPath = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon'
Set-ItemProperty $RegistryPath 'AutoAdminLogon' -Value "1" -Type String
Set-ItemProperty $RegistryPath 'DefaultUsername' -Value $Username -type String
Set-ItemProperty $RegistryPath 'DefaultPassword' -Value $Pass -type String
Restart-Computer

Automatic logon will not work if a logon banner policy is enabled on the computer: Computer Configuration -> Policies -> Windows Settings >Security Settings > Local Policies -> Security Options -> Interactive Logon : Message text for users attempting to log on.

The value of the DefaultUserName registry entry changes when a different user is logged on to the computer (it contains the name of the last logged in user). After this, the automatic Windows logon will no longer work.

Disable Password After Resuming from Sleep/Hibernation on Windows

Windows may require you to enter a password when your computer wakes from sleep or hibernation. This is called a Secondary Logon.

You can disable the password prompt after waking from sleep using the Windows Control Panel:

  1. Go to Settings -> Accounts -> Sign-in options (or run the quick access URL command: ms-settings:signinoptions );
  2. Change the value of the Require sign-in parameter from When PC wakes up from sleep to Never;disable sign-in screen after sleep
  3. Then check that dynamic screen lock is disabled here: Allow Windows to automatically lock your device when you’re away;windows: disable dynamic lock
  4. Disable the ‘On resume, display logon screen’ option in Control Panel if the screen saver is configured on a computer: control desk.cpl,,@screensaver disable logon screen after screen saver

You can disable the password when resuming from sleep with the commands:

powercfg /setacvalueindex scheme_current sub_none consolelock 0
powercfg /setdcvalueindex scheme_current sub_none consolelock 0

You can disable the password prompt after waking from sleep/hibernation using GPO:

  1. Open the Local Group Policy Editor snap-in – gpedit.msc (on Home editions of Windows, you can run the local policy editor as follows);
  2. Navigate to Computer Configuration -> Administrative Templates -> System -> Power Management -> Sleep Settings;
  3. Disable the GPO parameters “Require a password when a computer wakes (on battery)” and “Require a password when a computer wakes on battery (plugged in)”;gpo: require password when computer wakes
  4. Now Windows won’t ask for a password when you wake your computer from sleep or hibernation.
You can also turn off the screen lock completely in Windows.:

reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" /v "DisableLockWorkstation" /d 1 /t REG_DWORD /f

Enable Auto Sign-in to Windows with the AutoLogon Tool

You can store the user password in encrypted form in the registry using the Autologon utility. This is a more secure way to automatically log on to Windows. The Autologon is available for download from the Microsoft website as part of the Sysinternals toolset (https://learn.microsoft.com/en-us/sysinternals/downloads/autologon).

  1. Download and run Autologon.exe (or autologon64.exe) as an administrator;
  2. Accept the terms of the license agreement; sysinternals autologon tool
  3. Specify the user account, domain, and password that will be used to automatically log on to Windows. Click the Enable button:
    Autologon successfully configured. The autologon password is encrypted.
  4. An encrypted password is stored in LSA format under the HKLM\SECURITY\Policy\Secrets registry key. In this case, although the password is not stored in clear text, the encryption algorithm is not strong and technically any user with local admin permissions can decrypt it.using sysinternals autologon tool

You can set user credentials to automatically log on to Windows using the Autologon command-line options. Use the following syntax to enable passwordless logon:

autologon64.exe USER_NAME DOMAIN PASSWORD /accepteula

To disable automatic logon to Windows without a password, simply click the Disable button.  

We looked at how to disable the password login on Windows and automatically boot directly to the user’s desktop. Hold down the Shift key when Windows starts up if you want to temporarily disable automatic logon and manually select a user on the sign-in screen.

Automatic login to devices without a password is often used on devices operating in information kiosk mode. When such a device is booted up, Windows should automatically log on to the desktop and start the necessary programs via autorun.

It is not recommended to configure the automatic login to be for the built-in Windows Administrator account or for a user with local administrator permissions.

21 comments
8
Facebook Twitter Google + Pinterest
previous post
Repairing Broken Trust Relationship Between Workstation and AD Domain
next post
How to Create and Manage Distribution Groups (Lists) in Exchange?

Related Reading

Installing Language Pack in Windows 10/11 with PowerShell

September 15, 2023

How to View and Change BIOS (UEFI) Settings...

September 13, 2023

How to Create UEFI Bootable USB Drive to...

September 11, 2023

Redirect HTTP to HTTPS in IIS (Windows Server)

September 7, 2023

Add an Additional Domain Controller to an Existing...

September 6, 2023

Categories

  • Active Directory
  • Group Policies
  • Exchange Server
  • Microsoft 365
  • Azure
  • Windows 11
  • Windows 10
  • Windows Server 2022
  • Windows Server 2019
  • Windows Server 2016
  • PowerShell
  • VMWare
  • Hyper-V
  • Linux
  • MS Office

Recent Posts

  • Installing Language Pack in Windows 10/11 with PowerShell

    September 15, 2023
  • Configure Email Forwarding for Mailbox on Exchange Server/Microsoft 365

    September 14, 2023
  • How to View and Change BIOS (UEFI) Settings with PowerShell

    September 13, 2023
  • How to Create UEFI Bootable USB Drive to Install Windows

    September 11, 2023
  • Redirect HTTP to HTTPS in IIS (Windows Server)

    September 7, 2023
  • Add an Additional Domain Controller to an Existing AD Domain

    September 6, 2023
  • How to Install an SSL Certificate on IIS (Windows Server)

    September 5, 2023
  • Managing Windows Firewall Rules with PowerShell

    August 31, 2023
  • Fixing ‘The Network Path Was Not Found’ 0x80070035 Error Code on Windows

    August 30, 2023
  • Disable Welcome Message for Microsoft 365 Groups

    August 28, 2023

Follow us

  • Facebook
  • Twitter
  • RSS
Popular Posts
  • How to Repair EFI/GPT Bootloader on Windows 10 or 11
  • How to Restore Deleted EFI System Partition in Windows
  • Network Computers are not Showing Up in Windows 10/11
  • Updating List of Trusted Root Certificates in Windows
  • How to Create a Wi-Fi Hotspot on your Windows PC
  • How to Sign an Unsigned Device Driver in Windows
  • How to Download APPX File from Microsoft Store for Offline Installation?
Footer Logo

@2014 - 2023 - Windows OS Hub. All about operating systems for sysadmins


Back To Top