If your Mac doesn’t respond to key presses
If your Mac doesn’t respond when you press the keys on your keyboard, or if pressing some keys has unexpected results, try the following.
If no keys work on an external keyboard
Disconnect and reconnect the keyboard. Make sure the connector is completely inserted into the port.
Connect your keyboard to a different USB port or to a different Mac. If this solves the problem, your Mac may need to be repaired. Take it to an Apple Retail Store or an Apple Authorised Service Provider.
Connect a different keyboard to this Mac. If this solves the problem, you may need to take your keyboard in for service.
If some keys on your portable computer’s built-in keyboard don’t work
If the keyboard produces only numbers, make sure the Num Lock key’s indicator light is off. Press the Num Lock key to turn its light off.
If the Num Lock key doesn’t have an indicator light, press the key and try the keyboard again.
If none of the keys work, your Mac may be showing a low battery alert that you can’t see. Connect your Mac to an electrical outlet or connect an external keyboard to your Mac to see the alert.
If the Media Eject key or Caps Lock key doesn’t work
Try holding down the key longer. These keys have a slight delay to prevent an immediate response if they’re pressed accidentally. Press and hold the Media Eject key until the Media Eject icon appears on the screen, and press and hold the Caps Lock key until the key’s indicator light comes on.
If other keys don’t work
You may have accidentally set an option that changes how your keyboard operates.
Choose Apple menu > System Preferences, click Accessibility, click Keyboard, then click Hardware. Make sure Slow Keys is turned off. If Slow Keys is on, you must press and hold a key longer than usual before it’s recognised.
Choose Apple menu > System Preferences, click Accessibility, click Pointer Control, then click Alternative Control Methods. Make sure Mouse Keys is off. If Mouse Keys is on, pressing keys on the numeric keypad moves the pointer instead of entering numbers.
Choose Apple menu > System Preferences, click Keyboard, then click Input Sources. Select “Show Input menu in menu bar”. Open the Input menu, then make sure the correct keyboard layout is selected.
Open the Input Sources pane for me
To see the keyboard layout, click Keyboard, then choose “Show keyboard and emoji viewers in menu bar”.