Blog · October 5, 2026 · 7 min read
Cat on the Keyboard: Lock Your Mac's Keyboard, Trackpad and Mouse From Pets Without Turning the Screen Off
Every cat owner with a MacBook has a story. The Slack message that went out as "jjjjjjjjjjjjjjj". The terminal that was running a long job until a paw found Ctrl-C. The forty open tabs of whatever a tail drags across a trackpad. The one that actually hurts: coming back to find the agent you left working has been dismissed, the editor is in some mode you did not know existed, and the fan is screaming because a hind leg has been resting on the spacebar for twenty minutes. This post is about stopping that without turning the screen off, because the whole reason the Mac was left open was that something on it was worth watching.
Why the obvious fixes do not quite work
Lock the screen. Pressing Control-Command-Q locks the Mac, which does stop the typing, but it also blanks what you were watching and, after a few minutes, lets the display sleep. If you left a build, a download, a Claude Code run or a video on screen specifically so you could glance at it from the sofa, the lock screen defeats the purpose. It also does nothing about the cat sitting on the keyboard itself, which is a warm, pleasant thing to do, so you will have to move them when you come back anyway.
Close the lid. Same problem, plus the Mac goes to sleep and whatever it was doing stops, unless you have an external display and a power adapter and have set it up for clamshell mode, in which case the keyboard is covered but the external keyboard is not.
Put something on the keyboard. A book, a tray, a cardboard box. This works surprisingly often and costs nothing, and for a cat that likes the warmth it may be the kindest answer, but a determined animal will sit on the book and nudge the trackpad from there, and a box on the keyboard of a MacBook traps heat over the exact part of the machine that is trying to shed it.
A keyboard-lock utility. The small tools built for cleaning a keyboard, which we compared in the keyboard cleaning mode post, do block keystrokes while the screen stays on. For a cat, the gaps are the trackpad and the mouse: a cleaning tool that only swallows keys leaves a paw free to click, drag and open things, and most of the damage a pet does is clicks and drags, not typing.
What a pet-proof lock needs
- Keyboard and trackpad and mouse blocked, including scrolling and gestures. A tail on a Magic Mouse is a scroll event.
- The screen stays on and does not sleep, so what you were watching is still visible from across the room.
- Nothing a random key combination can do. Cats produce Command-Space, Command-Q and Command-Option-Escape by accident far more often than chance would suggest, because those keys are large and near the edges.
- An unlock that takes a human: a fingerprint or a password, not a keypress, because any keypress is exactly what the cat will do.
- No way for a stray click to surface something private. If Slack or your email is open behind the thing you were watching, a paw can bring it forward.
Setting up VibeLock for a cat (or a dog, or a parrot)
VibeLock was built for leaving coding agents running in view, but the problem is the same one: input must stop, the display must stay on, and the lock must only yield to a person. Here is the setup that works for pets.
- Choose what stays visible. From the menu bar, mark the apps you want to keep watching as visible: the terminal, the browser tab with the match on, the download window. Terminal, iTerm2, Warp, Ghostty, Claude, VS Code and a few others are pre-allowed. Everything else is hidden behind an opaque backdrop the moment you lock, including desktop files, and is kept hidden if it tries to come back. Leave the accessible list empty; that level is for pair sessions where a colleague needs to type, and a cat is not a colleague.
- Lock. A system-wide input firewall swallows every key, click, scroll and gesture on the built-in keyboard and trackpad and on anything plugged in. Spotlight, Force Quit and Command-Q are blocked system-wide, and VibeLock refuses to quit while locked, so there is no combination of paws that ends the lock.
- Walk away. The display is held awake while locked. The visible apps keep updating and keep playing; they just cannot be touched. Fullscreen windows of hidden apps on other Spaces are covered by the shield if a swipe lands there.
- Unlock with Touch ID, or type your Mac login password into VibeLock's own shield. It is verified locally against your account; nothing new to remember, and nothing a paw can trigger.
First-time setup takes one step: on the first lock, macOS asks you to grant the Accessibility permission that input blocking requires. VibeLock is a 2 MB native Swift app, signed and notarized by Apple, with no account and no network calls. It runs on macOS 13 Ventura or later and costs $10 once, with a 7-day refund if it is not for you.
Trade-offs, honestly
VibeLock stops the cat from doing anything. It does not stop the cat from being there. A MacBook keyboard is still a warm rectangle, and a cat lying across it still blocks the vents along the hinge, which matters if the thing you left running is a compile or a model that is already making the fans spin. If your cat's preferred spot is the keyboard itself rather than the trackpad, pair the lock with a stand that raises the Mac on an angle; cats are less fond of sloped surfaces, and the airflow improves.
It also will not help with the thing cats do to external displays and cables. A lock is for input; it has no opinion about a monitor being knocked off its arm.
And if you do not need the screen on, the free answer is still fine: Control-Command-Q, or close the lid. VibeLock earns its $10 in the specific case where you want to see what the Mac is doing while nothing and nobody can touch it. That is the agent-running case we wrote about in leaving Claude Code running while you are away, the video-on-the-kitchen-Mac case, and, it turns out, the cat case.
A note on toddlers
If the problem in your house walks on two legs, the same lock works but the surrounding advice is different; a child will try to unlock it and a cat will not. We covered that separately in toddler-proofing a Mac.