How to Disable a MacBook Keyboard (and Turn It Back On)

Short answer: macOS has no built-in switch to turn off the whole keyboard. System Settings can only set modifier keys to No Action. For cleaning, a free app such as Keyboard Clean Tool blocks the built-in keys until a trackpad or mouse button is held down. To ignore the built-in keyboard whenever an external one is connected, Karabiner-Elements has a Devices setting that disables it automatically.

A damp cloth dragged across a MacBook keyboard types. So does a cat walking across it, and so does an external keyboard resting on top of the built-in one. Each of those problems has a different fix, and Control+F1, a shortcut some sites suggest for how to disable a MacBook keyboard, fixes none of them.

The methods below follow Apple Support and the app makers’ own documentation as of November 2026. Below, match your reason to the method that actually works for it. Every method includes how to switch the keyboard back on, because getting locked out is the real risk here.

Which method fits your reason for turning the keyboard off?

Start with why you want it off. Cleaning needs a temporary lock. An external keyboard needs an automatic rule. A single bad key needs only that key switched off.

Your reasonUse thisTo undo
Cleaning the keysKeyboard Clean ToolHold a trackpad or mouse button
External keyboard on topKarabiner-Elements Devices settingUntick it, or uninstall
One stuck or broken keyKarabiner Simple ModificationsRemove the change
Kids or petsControl-Command-Q, or a lock appSign back in, or unlock the app
Keys typing by themselvesCheck settings, then Apple repairNot applicable

If only a modifier key is the problem (Caps Lock or Control, for example), System Settings can turn it off with no app at all. That’s covered further down.

How do I lock my MacBook keyboard to clean it?

Install Keyboard Clean Tool, start it, then wipe. Its maker, folivora.AI (which spells it KeyboardCleanTool), says it “Locks your keyboard (including modifier keys and the Touch Bar) and optionally trackpad, mouse and the touch display, so you can wipe them without producing any input.”

  1. Download it from the folivora.AI site.
  2. Open it and grant Accessibility permission when asked, at System Settings > Privacy & Security > Accessibility.
  3. Click the button to start the lock. The screen darkens, which makes smudges easier to see.
  4. Wipe the keys.
  5. Press and hold a trackpad or mouse button for a few seconds to unlock.

There’s no keyboard shortcut to unlock it. According to Switching To Mac’s September 2026 guide, shortcuts are left out on purpose so a child or pet can’t unlock it by accident.

Two things it can’t do. The power button is a hardware control, and the same guide says “apps can’t block it.” That includes Touch ID, so wipe around it gently.

The second limit matters if you use another keyboard. Switching To Mac warns that the tool may not reliably lock external Bluetooth or USB keyboards. Before you clean, switch off a Bluetooth keyboard at its power switch or unplug a USB one.

Keyboard Clean Tool at a glance

  • Price: free
  • Needs macOS 13 Ventura or later; the older KeyboardCleanTool 7 runs on macOS 10.11 to 12
  • Unlock: hold a trackpad or mouse button for a few seconds
  • Extras: prevents sleep while running, optional auto-unlock timer

Keep an Apple silicon MacBook from waking while you clean it

The simplest fix is to leave the Mac on and run Keyboard Clean Tool, since the app keeps it awake and blocks the keys. Shutting it down first doesn’t help much. Apple says a Mac laptop with Apple silicon “will automatically turn on and start up when you open its lid or connect it to a power source.” Pressing keys on a shut-down Apple silicon MacBook can start it up too.

If the lid and charger waking it are the annoyance, Apple lets you change that on Apple silicon MacBooks running macOS Sequoia 15 or later. Open Terminal (in Applications > Utilities) and type one of these, then enter your admin password. The password won’t show as you type.

Warning: these commands change a startup setting stored in your Mac’s NVRAM, a small memory area that holds settings the Mac reads when it starts.

  • Stop startup on lid open and on power: sudo nvram BootPreference=%00
  • Stop startup on lid open only: sudo nvram BootPreference=%01
  • Stop startup on power only: sudo nvram BootPreference=%02

To go back to normal: sudo nvram -d BootPreference

Apple notes this setting doesn’t stop the keyboard or trackpad from turning the Mac on.

How do I disable the built-in keyboard when an external keyboard is connected?

Use Karabiner-Elements and its “Disable the built-in keyboard while this device is connected” option. It’s a free keyboard customizer, and its docs say this setting suits people who rest an external keyboard on top of the built-in one. The built-in keyboard switches off when the external one connects and comes back when it disconnects.

  1. Open Karabiner-Elements.
  2. Click the Devices tab.
  3. Find your external keyboard in the list.
  4. Turn on “Disable the built-in keyboard while this device is connected.”
  5. If Karabiner doesn’t recognize your MacBook’s own keyboard, turn on “Treat as a built-in keyboard” for it.

Older guides, including the previous version of this page, send you to Devices > Advanced. That path is outdated. The setting now sits directly on the Devices tab.

Installing it takes a few permission steps. Open the downloaded DMG (a disk image file, like a virtual USB stick), run Karabiner-Elements.pkg, and follow the prompts in System Settings. The installation guide lists what it needs: permission for its background services, Accessibility, Input Monitoring, and a Driver Extension, which is the piece that creates its virtual keyboard and mouse.

You’ll see Input Monitoring listed under Privacy & Security. You don’t need to switch it on separately. The docs say “Accessibility permission also covers Input Monitoring permission, so it will be granted automatically when you allow Accessibility.” After that, pick a virtual keyboard layout that matches your physical keyboard.

Karabiner-Elements setup checklist

  • Current version: 17.0.0, released November 27, 2026, free
  • Runs on Intel and Apple silicon, macOS 13 Ventura through 27 Golden Gate
  • Grant: background services, Accessibility (covers Input Monitoring), Driver Extension
  • Setting lives on the Devices tab, not Devices > Advanced

How do I disable one stuck or broken key?

Map that key to vk_none in Karabiner-Elements’ Simple Modifications tab. It’s the cleanest way to disable keys on a Mac keyboard when one is stuck or broken and keeps repeating or misfiring.

  1. Install Karabiner-Elements as described above.
  2. Open the Simple Modifications tab.
  3. Select the target device first: your MacBook’s built-in keyboard.
  4. Choose the key you want to change.
  5. Set what it sends to vk_none.
  6. Open Karabiner-EventViewer and press the key to confirm nothing comes through.

The official docs say “First, select the target device, then choose the keys you want to modify.” EventViewer also shows each key’s name, which helps when you’re not sure what Karabiner calls a key. The meaning of vk_none comes from a community note on GitHub: it means “virtualkeyboard none,” used “when you want to disable any existing keybinding.”

Because the change belongs to one device, the same key still works on an external keyboard. If your built-in E key is repeating, you can switch off that one E and keep typing on a desk keyboard as normal.

Can I disable the keyboard without installing an app?

Only the modifier keys, each one set separately to “No Action.” Apple’s settings offer no switch for the whole keyboard. What they do offer is a way to set a modifier key to “No Action”. Modifier keys are the ones you hold with another key, such as Caps Lock and Control.

  1. Choose Apple menu > System Settings.
  2. Click Keyboard, then Keyboard Shortcuts.
  3. Click Modifier Keys.
  4. Open the pop-up menu next to the key and choose No Action.

To undo it, return to the same panel and click Restore Defaults.

This works on current macOS and goes back to Catalina 10.15. It’s handy for a Caps Lock that keeps catching your little finger. It can’t touch letter or number keys, so for those, use Karabiner.

How do I lock the keyboard from kids or pets?

For a quick stop, press Control-Command-Q to lock the screen. Apple lists it as the lock screen shortcut. Nothing a child or a cat types reaches your open apps, and you sign back in as usual. The downside is that you can’t watch a video or keep reading while it’s locked.

If you want the screen to stay visible while the keys do nothing, use a dedicated lock app. Cats Lock is a Mac App Store app by indie developer Todd Alexander. Engadget’s May 2026 write-up says it locks the keyboard “either with one click from the menu bar or using a keyboard shortcut, to block all typing when there’s a risk of a feline invasion.” It needs macOS Sonoma 14 or later, has a Stealth Mode and deterrent sounds, and unlocks on its own when the screen sleeps.

The developer’s site lists it at $4.99, a one-time purchase with no subscription. It freezes only the MacBook’s own keys, so an external keyboard keeps working. Check the App Store listing before you buy.

OptionWhat stays usableCost
Control-Command-QNothing until you sign inFree
Cats LockScreen, and the trackpad if you choose to leave it unlockedAbout $5
Keyboard Clean ToolTrackpad and mouse, unless you lock them too; the screen darkensFree

No app can block the power button. Holding it down forces the Mac off when it isn’t responding, so a determined toddler can still end the session.

Does Control+F1 or the Accessibility Keyboard disable the keyboard?

No to both. Control+F1 and the Accessibility Keyboard change how you use the keyboard. Neither switches the physical keys off.

Keyboard Shortcuts settings in an older macOS version, showing Control-F1 assigned to Turn keyboard access on or off
Keyboard shortcut settings.

Control+F1 is a reserved shortcut that, in Apple’s developer guide, “Turns full keyboard access on or off”. Full Keyboard Access does the opposite of what people searching for this want. Apple says that with it on, “you can use the keyboard to navigate your Mac, instead of using a mouse or trackpad.” It lives in System Settings > Accessibility > Motor > Keyboard. If you pressed Control+F1 by accident, press it again or turn Full Keyboard Access off there.

The Accessibility Keyboard is an extra keyboard drawn on screen. Apple describes it as “an onscreen keyboard that lets you use your Mac without a physical keyboard”. Apple’s page doesn’t say it disables the physical keyboard. To close it, click the Close button in its top-left corner.

Does the Terminal kextunload command still disable the keyboard?

Don’t rely on it. The Terminal command that still circulates dates from a 2014 guide written for Intel MacBooks of that era. It unloads AppleUSBTCKeyboard.kext, the keyboard’s kernel extension (a driver that runs inside the core of macOS). Two things have changed since then.

First, the tool itself is retired. The kextunload manual page says: “The kextunload utility has been deprecated. Please use the kmutil(8) equivalent: kmutil unload.”

Second, Apple changed how kernel extensions load. Apple’s platform security guide says that starting with macOS 11, third-party kexts can’t be loaded on demand and are instead bundled together at startup. On Apple silicon, they also require a trip into Recovery and a switch to “Reduced Security.”

Don’t lower your Mac’s security to make an old keyboard trick work. Karabiner-Elements does the same job, and you can undo it from a menu.

If you already ran the command on an older Intel Mac and the keyboard is still off, restarting the Mac is the simplest way to bring it back.

Why kextunload is a bad bet now

  • The tool is deprecated; Apple points to kmutil instead
  • Since macOS 11, kexts load as a bundle at startup, not on demand
  • On Apple silicon, third-party kexts need Reduced Security set in Recovery
  • The widely copied command dates from 2014-era Intel MacBooks

How do I get my keyboard working again?

Undo whichever method you used. Here’s each one in a single place.

  • Keyboard Clean Tool: press and hold a trackpad or mouse button for a few seconds.
  • Karabiner Devices setting: open the Devices tab and turn off “Disable the built-in keyboard while this device is connected.” Unplugging or switching off the external keyboard also brings the built-in one back.
  • Karabiner single key: remove the vk_none line from Simple Modifications.
  • Modifier keys: System Settings > Keyboard > Keyboard Shortcuts > Modifier Keys > Restore Defaults.
  • Lid and power setting: sudo nvram -d BootPreference in Terminal.

To remove Karabiner-Elements completely, use the Launch uninstaller button on its Uninstall tab and enter your admin password. From Terminal, the Karabiner uninstall guide gives two commands to run in order. Warning: these remove the app and its driver from your Mac.

bash '/Library/Application Support/org.pqrs/Karabiner-DriverKit-VirtualHIDDevice/scripts/uninstall/deactivate_driver.sh'

sudo '/Library/Application Support/org.pqrs/Karabiner-Elements/uninstall.sh'

Need to type but the keys are blocked? Apple suggests the on-screen Keyboard Viewer, clicked with the mouse or trackpad.

As a last resort, start up in Safe Mode, which Apple says helps “identify whether issues you’re experiencing are caused by software that loads as your Mac starts up”. On Apple silicon:

  1. Shut down the Mac.
  2. Hold the power button until “Loading startup options” appears.
  3. Select your startup volume.
  4. Hold Shift and click Continue in Safe Mode.

“Safe Boot” appears in the menu bar. Safe Mode keeps login items and extensions macOS doesn’t need from loading, so if the keyboard works there, a keyboard app or its driver is likely blocking it.

Why do keys type by themselves, and when should I go to Apple?

Check your settings first, then treat it as a hardware problem. A few Accessibility settings make a keyboard act broken when it isn’t. Apple’s key press troubleshooting page lists them:

Accessibility settings in an older macOS version, Pointer Control pane with the Enable Mouse Keys checkbox
Mouse Keys Setting in Big Sur.

Option-Command-F5 opens the Accessibility Shortcuts panel, so you can see what’s switched on at a glance. Mouse Keys was the “past method” on the old version of this page. It stops text entry, so it was never a true off switch.

If keys still fire on their own after those checks, a repair is the fix, and turning the key off in Karabiner only hides it. On current MacBook Air and MacBook Pro models, Apple’s self-repair parts list has no separate keyboard: apart from keycaps, it comes as part of the whole top case. The free butterfly keyboard program has ended; Apple’s page now reads “The Apple Service Program you are looking for has ended.” MacTrast reported in November 2024 that it covered MacBook, MacBook Air and MacBook Pro models sold from 2015 to 2020, each for four years.

Book through Apple’s Mac laptop repair page or an Apple Authorized Service Provider. Apple warns that “Repairs performed by untrained individuals or using nongenuine Apple parts may affect the safety and functionality of the device.”

Keyboard repair basics

  • The Apple Limited Warranty covers manufacturing issues for one year from purchase
  • It excludes accidental damage
  • With AppleCare, the fee is the same at Apple and authorized providers
  • Apple publishes estimated fees for out-of-warranty service; get a quote for your model

The Bottom Line

If you only want to clean the keys, install Keyboard Clean Tool, switch off any external keyboard, and leave the Mac running. Hold a trackpad button when you’re done.

If an external keyboard sits on top of your MacBook, Karabiner-Elements is worth the few minutes of permission prompts. Its Devices tab handles it automatically, and the same app can silence a single broken key.

If keys type on their own after you’ve checked Mouse Keys and Slow Keys, book a repair rather than living with a workaround. Skip Control+F1 and the old Terminal command entirely.

Questions People Also Ask

How do I turn off my MacBook Air with the keyboard?

Press Control-Option-Command-Power button, which Apple says will “quit all apps, then shut down your Mac.” If the Mac isn’t responding, press and hold the power button to force it off. On Apple silicon models, pressing the keyboard or trackpad can turn it back on. The Terminal setting Apple documents changes only the lid and power behavior, not that.

Does Keyboard Clean Tool also block my Bluetooth keyboard?

It may not. Switching To Mac warns that it may not reliably lock external Bluetooth or USB keyboards, and recommends turning Bluetooth accessories off at their power switch or unplugging USB ones before cleaning. The maker’s page doesn’t address external keyboards.

Can I disable the MacBook keyboard without an app?

Only the modifier keys, by setting them to No Action in System Settings > Keyboard > Keyboard Shortcuts > Modifier Keys. Apple’s modifier key settings offer no switch for letter keys or the whole keyboard. For a quick block with no app, Control-Command-Q locks the screen instead.

Why is my MacBook keyboard not typing letters?

Mouse Keys is one possible cause, because while it’s on you can’t use the keyboard to enter text. Turn it off in System Settings > Accessibility > Pointer Control. If that’s not it, check Slow Keys, your keyboard layout, and whether a locking app is still running.

How do I disable the trackpad too while cleaning?

Keyboard Clean Tool can lock the trackpad as an option, so set its unlock timer or have a mouse ready. Separately, macOS can ignore the built-in trackpad when a mouse or wireless trackpad is present, under System Settings > Accessibility > Pointer Control. Apple warns that a non-Apple mouse’s driver software may stop that option working as expected.

Why isn’t my external keyboard working on my MacBook?

Check the connection first: for Bluetooth, make sure the keyboard is on and charged and Bluetooth is on, then disconnect and reconnect it; for a wired one, unplug it and plug it back in fully. Apple’s troubleshooting steps then suggest a different port or Mac, and a different keyboard. Whichever swap fixes it tells you whether the Mac or the keyboard needs service.

Sources

Leave a Reply

Your email address will not be published. Required fields are marked *

  • DeusExMachina

    Full Keyboard Access was never designed to do this, nor would that even make any sense. Full Keyboard Access is in Accessibility because it is designed for people with limited ability to control a mouse or trackpad to use their keyboards to control GUI interface elements, using the Tab and other keys.

    Reply
    • Eric

      Hi DuesExMachina,

      Thank you for the comments, I appreciate the feedback. I agree with the reason that this is in Accessibility. The intent here was to explore the different methods out there that people have said would work to disable the keyboard. It was not really concerned with whether that was the original intent or design of the functionality or not. For me, this method did not work as others out there have said that it would and it looks like the best route for doing this is to use a third-party application. Some of the apps I have tried did work and produced the results I was looking for. Thanks again for the feedback, it was great to hear from you.

      Reply
  • Claws

    Karabiner-Elements caused very strange input mappings for my Goldtouch ergo keyboard. Most punctuation and symbols were dramatically wrong at first. I’d originally planned to come up with complex mappings to fix each one but then tried two things. I’m not sure which fixed it but it seems to be consistently fixed.
     > System Preferences > Keyboard > Keyboard > “Use F1, F2, etc….”
     > System Preferences > Keyboard > Input Sources > Show Input menu in menu bar

    With both settings on, the external keyboard now functioned perfectly. The strangest part is that the fix seems to persist even when the settings are unchecked and across reboots.

    Now, my cat can sit on the warm laptop all day. 🙂

    Reply
  • Dio Gratia

    I gave Karabiner-Elements 14.4.0 a try and had a bit of difficulty initially on MacOS 12.4.2. Once I got the Input Monitoring squared away (Hint use the allow button to give the Application all it wants in System Preferences => Security & Privacy, the author is terribly good at scripts) I could disable the internal keyboard (Macbook M1 2020) using an external Apple keyboard (A1242 USB) leaving the Touch ID and Trackpad functional with a single checkbox under Karabiner-Elements.app => Karabiner-Elements Preferences => Devices => Advanced.

    The reason for disabling the internal keyboard is key damage that also prevents Shutdown from being persistent.

    I may try the kextunload method show in Nick’s linked Stack Exchange SuperUser link https://superuser.com/a/665971 to see if I can get powerdown to stick (after carefully documenting so I can get a replacement keyboard to work).

    Reply
    • Eric

      Thanks for the great information. I appreciate the tips and feedback and am glad that this is working for you.

      Reply
  • Mike Draught

    I place my external keyboard over top of my MacBook built-in keyboard to enable “industrial strength” typing. Unfortunately, the external keyboard tends to shift around and its legs tend to touch parts of the built-in kb, creating some unwanted results. I’d like to put the build-in kb to sleep EXCEPT for its power/touchID key [far right top row]. Do you see any solution? Even a hard, flat partial cover would probably work, but I can’t find one that suits.

    Reply
    • Eric Winkler

      Hi Mike,

      Sounds like your worry is not from other things touching the keyboard and creating issues, but just the external keyboard being on top and it may inadvertently hit the keys or even the touchpad.

      It’s possible you may not really need to disable the keyboard but you could put something on each side of the built-in keyboard that is just a bit thicker than the laptop and then lay the external keyboard across so that it is just above the built-in keyboard but not touching it. You could try using some books, DVD cases, or something like that of equal thickness.

      See my example here: https://macosx-faq.com/wp-content/uploads/eric-macbook-keyboard.png

      Reply
      • Mike Draught

        My son just built an ingenious, 4-legged, rectangular stand out of wood with two long and two short legs. the bottom tips of the legs are rubberized to prevent slippage. It sits just above the laptop’s built-in keyboard and rests on the desk surface, Works great and retains access to the power/fingerprint button.

        Reply
  • Ary

    I have an external keyboard and I wanted to find a way to turn off my computer keyboard so I could use my external keyboard. Control F1 worked perfectly for me! I wanted to pass this along in case anyone else was frustrated like me lol. Thanks for the help!

    Reply
    • Jerry Romero

      Thanks for sharing this great tip!

      Reply
    • Jerry Romero

      Thanks for sharing, Nick. Will give it a try and see how it works.

      Reply