Skip to content

Keyboard locker: lock the keyboard with a hotkey.

Press Ctrl+Alt+Win+Backspace and the keys do nothing, so you can wipe the keyboard, or leave a toddler or a cat at the desk, and nothing gets typed. The mouse still works. Click Unlock on the card in the corner of the screen when you're done.

Block User Input is in Pro and the free 14-day trial. No script to write.

Ctrl+Alt+Win+Backspace locks the keyboard. Unlock gives it back.

The hotkey runs Block User Input, set to Keyboard only, and then shows a small card in the corner of the screen: Keyboard locked, with an Unlock button. Keys do nothing until you click it. The mouse still works.

Clicking Unlock ends the macro, and the block lifts with it. The emergency stop key, Ctrl+Alt+End unless you changed it, unlocks it too.

The macro Keyboard locker running in MacroWin: Ctrl+Alt+Win+Backspace is pressed, Block User Input locks the keyboard and a card that says Keyboard locked shows in the corner of the screen. Keys pressed on the keyboard type nothing into the text box beside it. The pointer clicks Unlock on the card, the macro ends, the block lifts and a key types again.

Set it up.

Install in MacroWin

Needs Pro or the free 14-day trial. It arrives switched off.

Or in MacroWin: Ctrl+N, then pick the Keyboard locker template.

MacroWin didn't open

MacroWin doesn't seem to be installed on this PC. Download it and install it, then click Install in MacroWin again.

Already have it? Update it to the latest version, or open the Macro Hub in MacroWin and search there.

Download MacroWin

Or build it yourself

  1. New macro, trigger Hotkey.
  2. Press Ctrl+Alt+Win+Backspace in the Hotkey field.
  3. Add Block User Input, Input to block Keyboard only.
  4. Add Popup With Buttons, Title Keyboard locked, Button 1 Unlock.
  5. Empty Button 2, and set Close after (ms) to 0.
  6. Ctrl+S, then switch Enabled on.

Lock the keyboard your way, and how to get out.

What gets locked, and for how long, is set in Block User Input.

Variations

Keyboard and mouse
Set Input to block to Keyboard and mouse to lock both, for a cat that walks over the mouse too. You can't click Unlock then, so unlock with the emergency stop key, or give it a time limit.
Only the mouse
Mouse only locks moves, clicks and the wheel, and the keys still work. The emergency stop key unlocks it.
For a set time
Set Block for at most (ms), such as 60000 for a minute, and the keys come back by themselves. Set the card's Close after (ms) to the same, and the card goes too.
When a game or video goes full screen
Swap the Hotkey for a Full-Screen App trigger, and the keys lock as soon as a child's game or a video fills the screen. Unlock still gives them back.

Getting out, and limits

Unlock
Click Unlock on the card. The macro ends and the keys work again. Stop all, in MacroWin's tray menu, does the same.
The emergency stop
Ctrl+Alt+End, unless you changed it in Settings > Input, gets through even while the keys are locked, and lifts the block at once.
Ctrl+Alt+Del
Always works. Windows keeps it for itself.
No unlock key
A locked keyboard passes no keys, so no key combination of your own can unlock it. That's why the card has a button you click.
Not Win+L
Win+L locks the whole PC and asks for your password. The keyboard locker leaves the screen and your apps as they are; only the keys stop.
Macros still type
Only your own keys are locked. Keys and clicks that MacroWin's macros send still go through.

FAQ

How do I unlock the keyboard?

Click Unlock on the Keyboard locked card in the corner of the screen. The macro ends and the keys work again. The emergency stop key, Ctrl+Alt+End unless you changed it, unlocks it too, and so does Stop all in MacroWin's tray menu.

Do I need to write a script?

No. You pick steps from a list and fill in their settings, or install the ready-made macro from this page. There is no code or script to write.

What if the mouse is locked too and I can't click Unlock?

Press the emergency stop key, Ctrl+Alt+End unless you changed it. It always gets through and lifts the block at once. Ctrl+Alt+Del always works as well, since Windows keeps it for itself.

Can it lock the keyboard and mouse together?

Yes. Set Input to block to Keyboard and mouse. Mouse only locks moves, clicks and the wheel and leaves the keys alone. With the mouse locked you can't click Unlock, so use the emergency stop key, or set Block for at most so it unlocks by itself.

Why can't I unlock it with another hotkey?

A locked keyboard passes no keys, so no key combination can get through. The emergency stop key is the one exception. That's why the card has an Unlock button you click with the mouse.

Is it the same as Win+L?

No. Win+L locks the whole PC: Windows shows the sign-in screen and asks for your password. The keyboard locker locks only the keys. The screen stays as it is and the mouse still works.

Does it work in games and full-screen videos?

Yes. Block User Input stops your keys from reaching any app, a game or a full-screen video included. The card doesn't take the focus, so the app you were in stays in front.

Is the keyboard locker free?

MacroWin itself is free. Block User Input and Popup With Buttons are in Pro and the free 14-day trial. Pro is a one-time payment.

Read more about it.

Every step has its own page with all its settings, and the guides explain the ideas behind them.

Get the keyboard locker

Free, no account needed. Windows 10 and 11.

Download