Windows 10 Logo

There are several different ways you can lock your Windows 10 PC like the Windows key+L keyboard shortcut. If your Windows key is broken but you still want a quick way to lock your PC, create a desktop shortcut.

First, right-click anywhere on the Desktop and a menu will appear. Here, hover your cursor over the “New” option and then select “Shortcut” from the submenu.

Once selected, the “Create Shortcut” window will appear. Here, type or paste the following command in the “Type The Location Of The Item” text box, and then click the “Next” button.

Rundll32.exe user32.dll,LockWorkStation

Command for creating a lock shortcut

Note: You can lock your Windows 10 PC using Command Prompt or the Run by using this same command.

Next, give your new shortcut a name. Type in a name that complements its functionality so that you (or anyone else using the PC) will know exactly what it does. Type the name in the box under “Type A Name For This Shortcut.” Once ready, click “Finished.”

Name the desktop shortcut

The desktop shortcut will now appear on your desktop.

When you want to lock your Windows 10 PC, double-click this desktop icon.

No matter how you decide to lock your PC, it’s always recommended that you do so—even if you’re just stepping away for a minute or two.

Profile Photo for Marshall Gunnell Marshall Gunnell
Marshall is a writer with experience in the data storage industry. He worked at Synology, and most recently as CMO and technical staff writer at StorageReview. He's currently an API/Software Technical Writer based in Tokyo, Japan, runs VGKAMI and ITEnterpriser, and spends what little free time he has learning Japanese.
Read Full Bio »