Keyboard Cleaner: Lock Keys While You Clean

Keyboard Cleaner cleans nothing: it ignores the key presses this page receives, and mouse clicks if you choose, while you dust your keyboard. It unlocks after 30 s, 1 min or 2 min, or when you press and hold Hold to unlock.

Dust only while the computer is on

Use a soft brush or compressed air. For a damp cloth, shut the computer down or unplug the keyboard first, and never spray or pour liquid onto the keys. Apple, for one, says to shut a MacBook down before you wipe it.

Lock for
Touchpad taps and scrolling too. Hold to unlock still works.

Not locked. Choose a length under Lock for, then press Start cleaning.

What still gets through while locked

  • Chrome, Edge and Opera on Windows: In fullscreen, Keyboard Lock holds back Esc, so you press and hold Esc to leave fullscreen, which also unlocks. It can also hold back system shortcuts such as Alt+Tab and the Windows key.
  • Chrome, Edge and Opera on a Mac: In fullscreen, Keyboard Lock should hold back Esc, so you press and hold Esc to leave fullscreen, which also unlocks. System shortcuts such as Command+Tab still work: macOS keeps them.
  • Firefox and Safari: Esc leaves fullscreen, which also unlocks. System shortcuts such as Alt+Tab, Command+Tab and the Windows key still work, and so do browser shortcuts such as Ctrl+W, Command+W and Command+Q. Closing the tab ends the lock.
  • Every browser: On Windows, no web page can block Ctrl+Alt+Del. The power button, Fn and Fn Lock (often handled by the keyboard itself), and the volume, brightness and media keys may still work.

Runs entirely in your browser. Test results, audio and video never leave your device.

How to lock your keyboard while you clean it

  1. Under Lock for, choose 30 s, 1 min or 2 min. The lock ends by itself when that time runs out; 1 min is the default.
  2. Tick Also ignore mouse clicks if a palm or the brush might press the touchpad or the mouse, as on a laptop.
  3. Press Start cleaning. The page fills the screen where the browser allows it and counts the key presses it ignores.
  4. Dust the keys with a soft brush, or blow between them with compressed air. Keep liquids away while the computer is on.
  5. To stop early, press and hold Hold to unlock for 2 seconds with the mouse, the touchpad or a finger. Leaving fullscreen also unlocks.
  6. Check the keys afterwards with the Keyboard Test.

What does a keyboard cleaner do?

A keyboard cleaner page cleans nothing: it ignores the key presses it receives while you dust the keyboard, so they do not type text or scroll the page. Some keys can still act, such as Ctrl+Alt+Del on Windows, which no web page can block, and system shortcuts. Before wiping with a cloth, check the maker's advice: Apple says to shut a MacBook down first.

Which keys still work while the page is locked

This page is for the keyboard, and for the touchpad and mouse with Also ignore mouse clicks. To find dust and smudges on the screen, use the Screen Cleaner.

A web page can ignore only the key presses the browser passes to it, so what gets through depends on the browser and the system.

Browser and systemWhat still gets through
Chrome, Edge and Opera on WindowsIn fullscreen, Keyboard Lock holds back Esc, so you press and hold Esc to leave fullscreen, which also unlocks. It can also hold back system shortcuts such as Alt+Tab and the Windows key.
Chrome, Edge and Opera on a MacIn fullscreen, Keyboard Lock should hold back Esc, so you press and hold Esc to leave fullscreen, which also unlocks. System shortcuts such as Command+Tab still work: macOS keeps them.
Firefox and SafariEsc leaves fullscreen, which also unlocks. System shortcuts such as Alt+Tab, Command+Tab and the Windows key still work, and so do browser shortcuts such as Ctrl+W, Command+W and Command+Q. Closing the tab ends the lock.
Any browser without fullscreenEsc is ignored like the other keys, but system and browser shortcuts still work, and closing the tab ends the lock. Browsers on iPhone cannot go fullscreen.
Every browserOn Windows, no web page can block Ctrl+Alt+Del. The power button, Fn and Fn Lock (often handled by the keyboard itself), and the volume, brightness and media keys may still work.

How to clean a keyboard safely

  • Check the cleaning advice from the maker of your keyboard or laptop first, and follow it where it differs from these tips. Apple's cleaning guide, for one, says to shut down a MacBook and unplug the power adapter before you clean it.
  • While the computer is on, dust only: use a soft brush, or short bursts of compressed air with the can held upright.
  • For a damp cloth, shut the computer down or unplug the keyboard first, and take the batteries out of a wireless one.
  • Dampen the cloth, not the keyboard: never spray or pour liquid onto the keys, and let them dry fully before you switch back on.
  • If keys seem locked or type the wrong characters, check Num Lock or Fn Lock, or test them with the Keyboard Test.

What the Keyboard Cleaner does and does not do

  • Ignores the key presses that reach the page while locked, so cleaning does not type text, scroll or set off the browser shortcuts a page can block.
  • Shows how many key presses it ignored. It never records or sends which keys they were.
  • With Also ignore mouse clicks ticked, ignores clicks, taps and scrolling on the page too, except on Hold to unlock.
  • Says on the lock screen whether Esc is held back and which shortcuts still act, for this browser on this system.
  • Keeps the screen awake while locked, where the browser has the Screen Wake Lock API.
  • Cleans nothing, and does not disinfect, dry or switch off the keyboard.

How it works

Start cleaning asks for Keyboard Lock, then fullscreen, and opens a black lock screen. While locked, the page cancels every key event it receives, and with Also ignore mouse clicks every click, touch and wheel event, before anything else on the page sees it. A held key counts once. With Keyboard Lock, Esc reaches the page first, and on Windows so can Alt+Tab and the Windows key.

The lock ends after 30, 60 or 120 seconds, a 2-second hold on Hold to unlock, or when the page leaves fullscreen. Meanwhile the Screen Wake Lock API keeps the screen on.

Limitations

  • It only ignores input that reaches this page. No web page can block Ctrl+Alt+Del on Windows, and the power button, Fn and Fn Lock, and the volume, brightness and media keys may still work. On a Mac, system shortcuts such as Command+Tab still work in every browser.
  • Keyboard Lock works only in fullscreen, and Firefox and Safari do not have it. There, Esc leaves fullscreen and unlocks, so brushing across Esc can end the lock early, and browser shortcuts such as Ctrl+W and Command+Q still act.
  • If a shortcut opens a menu or another window, such as the Windows key opening Start, the key presses after that go there instead of to this page.
  • Dust only while the computer is on. For a damp cloth, shut the computer down or unplug the keyboard first.
  • Hold to unlock needs a mouse, touchpad, finger or pen held on it; Space and Enter cannot hold it while locked, so cleaning never unlocks it by accident. With only a keyboard or a screen reader, wait for the time under Lock for to run out.

Frequently asked questions

Does the Keyboard Cleaner turn off my keyboard?

No. The keyboard keeps working, and only this page ignores the key presses it receives while locked. Other apps are not affected, no web page can block Ctrl+Alt+Del on Windows, and the power button and Fn keys may still work.

How do I unlock the keyboard?

Press and hold Hold to unlock for 2 seconds with the mouse, the touchpad or a finger, or wait for the time you chose under Lock for to run out. Leaving fullscreen also unlocks: press and hold Esc where Keyboard Lock holds it back, or press it once in Firefox and Safari.

Can I clean a laptop keyboard without turning the laptop off?

Yes, for dry dusting with a brush or compressed air, if your laptop's maker allows it, though some keys, such as the power button, may still act. Tick Also ignore mouse clicks to ignore the touchpad too, and shut the laptop down before using a damp cloth. To check the touchpad afterwards, use the Mouse Test.

Why did the lock end when I pressed Esc?

Because Keyboard Lock was not on, as in Firefox and Safari, so Esc left fullscreen, and leaving fullscreen unlocks the keys. Chrome, Edge and Opera can hold Esc back in fullscreen; there you press and hold it to leave.

Are the keys I press recorded?

No. The page counts how many key presses it ignored, but never which keys, and the count stays on your device.