KeySafe: Block Input for Clean icon
macOS
KeySafe
Get it
DISPATCH·4 min

KeySafe — Lock the MacBook keyboard for cleaning, presenting, or stepping away

Stop accidental typing instantly. KeySafe locks your keyboard so you can clean, present, or step away without random key presses. Menu-bar app, privacy-first, one-tap lock.

#app#macos#drish-labs
·by drish labs

What is KeySafe?

KeySafe is a small Mac utility that disables your keyboard on demand. Hit the menu-bar icon (or the global hotkey), and every keystroke stops registering until you unlock it. The trackpad and mouse keep working normally, so you can still see what's happening on screen, accept prompts, and unlock when you're done.

It's the kind of utility that does exactly one thing and then gets out of your way.

The problem

Every MacBook user has run into this. You want to wipe crumbs off your keys — so you open a text editor, turn off the keyboard by… well, you can't, actually. macOS ships no first-class way to lock the keyboard. So you either close your laptop (bad for cleaning), unplug the keyboard (impossible on the built-in one), or put the OS into an inaccessible state (hard to undo with dirty hands).

Other scenarios where this bites:

  • Cats walking across the keyboard during a call
  • Toddlers mashing keys while you're showing them a video
  • Screen-sharing where you want to demonstrate the mouse without stray keystrokes
  • Cleaning the keyboard with a damp cloth without triggering Spotlight forty times

What it does

  • Lock the keyboard from the menu-bar with one click
  • Keeps the mouse and trackpad fully active — you stay in control of the session
  • Global failsafe hotkey, customizable, to unlock from a locked state
  • Lightweight menu-bar app with minimal CPU and memory footprint
  • Privacy-first: requires Accessibility permission only, no data leaves your Mac

How it works

KeySafe uses macOS's CGEvent tap to intercept keyboard events at the system level. When the lock is on, the tap swallows each keystroke before it reaches the focused app. That means it works across every app — Safari, Finder, Zoom, your terminal, a full-screen game — without needing per-app integrations.

The Accessibility permission is what grants the right to install that tap. KeySafe asks for it once on first launch and never asks again. It doesn't record what you type, doesn't log events, doesn't connect to the internet. The only thing the permission enables is the lock itself.

Unlocking is deliberately friction-light but not accidental. You either click the menu-bar icon (reachable with a mouse when the keyboard is off) or press the customizable global hotkey. The hotkey survives lock-mode because the event tap allows the exact combo through.

Who it's for

  • Mac users who clean their own keyboards
  • Parents and pet owners with cats/kids who find laptops irresistible
  • Presenters and educators doing screen-shares where stray keystrokes break the flow
  • Anyone who's ever typed a Slack message into the wrong window because they set their laptop on a table and leaned on it

Real scenarios

Cleaning the keyboard. Spray a bit of keyboard cleaner on a cloth, lock KeySafe, wipe every key without watching letters accumulate in your editor. Unlock when done.

A Zoom demo. You're screen-sharing a product demo. You want to narrate and point with the mouse, but you keep bumping the trackpad and typing into the shared editor. Lock the keyboard, keep the trackpad live, demo cleanly.

Laptop on the dining table. You're showing your parents vacation photos on the Mac, and every time someone leans an elbow on it the slideshow restarts. Lock it, scroll with the trackpad, relax.

Why I built it

Mac power users accumulate tiny irritations. Each one is small — five seconds lost, a minor misunderstanding, a wrong window typed into. Individually, none worth fixing. Collectively, a death by paper cuts.

The best indie Mac apps are the ones that address exactly one of those paper cuts and charge a small price for a permanent fix. KeySafe is one of those. A feature that should have shipped with macOS, didn't, and now exists as a 5 MB download.

Alternatives and how it compares

  • Karabiner-Elements: powerful keyboard-remapping tool that can disable input, but setup is non-trivial and the mental model is much larger than what this use case needs.
  • KeyboardCleanTool (FromFolivora): free, does keyboard + trackpad disable. KeySafe differs in that it keeps the trackpad active (so you can still use the Mac) and offers a global unlock hotkey.
  • Just closing the laptop: not a real option when you want to see the screen while cleaning.

KeySafe's niche: the keyboard goes off, the Mac stays usable.

FAQ

Will KeySafe block the power button or Touch ID? No. System-level hardware events (power, Touch ID, brightness, volume) stay under macOS's control. Only the regular typing keys are intercepted.

Does it survive a sleep/wake cycle? Yes. The event tap is re-established on wake. If you sleep the Mac while locked, it comes back locked.

Is the Accessibility permission a security risk? The permission grants KeySafe the ability to see keystroke events. That's the only way a userland app can block them. KeySafe does nothing else with that stream — no logging, no network, fully auditable from the App Store sandbox.

Does it work on external keyboards? Yes. CGEvent taps run at the window server level, so external USB and Bluetooth keyboards are locked too.

Try KeySafe

Get on the App Store →

KeySafe is shipped under DRISH LABS — see the full catalog for every other app.

— end of article —

Ready to try KeySafe?