
Windows 10 and 11 automatically lock your PC after a period of inactivity as a security measure, but this feature can be frustrating when you want to maintain an active session. Here's how to disable automatic locking through various methods.
Why Windows Auto-Locks Your PC
Windows automatically locks your PC to:
- Protect against unauthorized access
- Comply with corporate security policies
- Save power by turning off the display
- Trigger after screensaver activation
Method 1: Adjust Power & Sleep Settings
- Open Settings (Win + I)
- Navigate to System > Power & sleep
- Under "Screen" set both values to "Never"
- Under "Sleep" set both values to "Never"
Method 2: Disable Screensaver Lock
- Open Settings > Personalization > Lock screen
- Click Screen saver settings
- Uncheck "On resume, display logon screen"
- Set "Wait" to a high value or choose "(None)"
Method 3: Modify Group Policy (Pro/Enterprise)
- Press Win + R, type
gpedit.msc
- Navigate to:
Computer Configuration > Administrative Templates > Control Panel > Personalization - Double-click "Do not display the lock screen"
- Set to Enabled
- Also configure:
- Interactive logon: Machine inactivity limit (set to 0)
Method 4: Registry Editor Method
- Press Win + R, type
regedit
- Navigate to:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System
- Create or modify these DWORD values:
-InactivityTimeoutSecs
= 0
-DisableLockWorkstation
= 1 - Restart your PC
Method 5: Disable Dynamic Lock
- Open Settings > Accounts > Sign-in options
- Under "Dynamic Lock" uncheck:
"Allow Windows to automatically lock your device when you're away"
Advanced: Disable Automatic Lock via Command Line
powercfg -change -standby-timeout-ac 0
powercfg -change -standby-timeout-dc 0
powercfg -change -monitor-timeout-ac 0
powercfg -change -monitor-timeout-dc 0
Security Considerations
While disabling auto-lock is convenient:
- Never disable on shared computers
- Consider alternative security measures
- Use physical security for unattended devices
- Corporate environments may enforce policies
Troubleshooting
If settings don't apply:
- Check for conflicting Group Policies
- Verify no admin has set mandatory timeouts
- Update Windows to latest version
- Reset power plan to defaults
For most users, adjusting Power & Sleep settings combined with screensaver configuration provides the best balance between convenience and security.