How to Auto Lock Windows 10 After Inactivity🔐 (GPO)

Using GPO or Registry, you can configure Windows to auto lock itself after inactivity or a user not using the computer for some time. Here’s how.

You can lock a Windows PC in a number of ways. Though not hard, locking Windows 10 is still a manual action. If you want to, you can configure Windows 10 to lock automatically after inactivity. You can specify the inactivity time like ten minutes, fifteen minutes, etc. If you find yourself frequently moving away from your computer then auto-locking Windows is quite useful and secure too.

In this quick guide, let me show the procedure to auto lock Windows after inactivity.

Steps to Auto Lock Windows 10 After Inactivity

The easiest way to make Windows 10 lock itself is to use the Group Policy editor. In the editor, you change a single policy and you are done. Do keep in mind that this method only works on pro and enterprise versions of Windows 10. If you are using Windows 10 home version then follow the second method. i.e, registry method.

Enable Windows Auto Lock After Inactivity via GPO

  1. Open the Start menu.
  2. Search and open “gpedit.msc“.
    Group policy start menu search
  3. In the GPO Editor, go to the following folder.
    Computer Configuration → Windows Settings → Security Settings → Local Policies → Security Options
    Windows 10 automatically lock 01
  4. Double-click on the “Interactive Logon: Machine inactivity limit” policy.
    Windows 10 automatically lock 02
  5. Type number of seconds after which you want Windows 10 to lock itself automatically. Choose the number of seconds between 1 and 599940.
    Windows 10 automatically lock 03
  6. Click on the “Apply” button.
  7. Click “Ok“.
  8. Close Group Policy Editor.
  9. Reboot Windows.
    Windows 10 automatically lock 04

After restarting, the policy will be applied. From now on, the computer will lock itself after the specified inactivity time.

To disable auto lock, just set the seconds value to 0 or empty in step 5 and save the changes.

Registry Method to Automatically Lock Windows 10 After Inactivity

If you are using Windows 10 home version, then you need to use the registry editor to automatically lock the computer. All you have to do is create a single value. Though editing registry for this specific purpose is nothing hard, I’d recommend you to backup the registry. The backup allows you to restore the registry if anything bad happens.

1. First, open the start menu, search for Registry Editor and press the enter button to open it.

Registry start menu search

2. In the registry editor, copy the below path, paste it in the editor’s address bar and press Enter. You will be instantly taken to the folder where you need to add the new value.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System

Windows 10 automatically lock 05

3. We now need to create a new DWORD value. So, make sure the System folder is selected in the left panel. Next, right-click on the right panel and select “New -> DWORD (32-bit) Value” option.

Windows 10 automatically lock 06

4. Name the new DWORD value as “InactivityTimeoutSecs” and press Enter to confirm the name.

Windows 10 automatically lock 07

5. After creating the DWORD value, double-click on the value. In the Edit Value window, select the “Decimal” radio option and enter the number of seconds in the blank field. Make sure that the number is seconds are between 1 and 599940. In my case, I’m entering 600 for 10 minutes. Click on the “Ok” button to save the changes.

Windows 10 automatically lock 08

6. This is how it looks like in the registry editor after setting up the value.

Windows 10 automatically lock 09

7. To apply the changes we just made, reboot your system.

Windows 10 automatically lock 04

After rebooting, your computer will automatically lock after inactivity. If you want to disable the automatic lock feature, all you have to do is enter 0 in step 5 or delete the InactivityTimeoutSecs DWORD value.

That is all. It is that simple to configure Windows 10 to automatically lock itself after inactivity.

If you like this article, do check out how to resize images from right-click menu and how to change default computer name in Windows 10.

Leave a Comment

Scroll to Top