Account

What new tool do you want?

Fun & Games

Keyboard Tester

Check that every key on your keyboard works. Press a key and it lights up, stays marked once tested, and shows the key name and code the browser received.

How to use

  1. 1Click the page, then press each key you want to check.
  2. 2A key that lights up and stays highlighted was received. Reset clears the marks.

Frequently asked questions

Why doesn't a key light up?

If the last-key line also stays blank, the browser never received it. That usually means the key is dead, or the operating system used it as a shortcut before the page could see it.

Why do left and right Shift look like two keys?

They are. Each physical key has its own code, so a dead left Shift can fail while the right Shift still works.

Does this work on a phone?

Yes, if the on-screen keyboard is open and this page is focused. Keys that the phone's keyboard does not offer, such as function keys, cannot be tested that way.

What a lit key actually proves

The map listens for keydown and keyup on the window. When a key goes down it is painted solid, added to the tested set, and the line above the map shows the character (event key) and the physical code (event code). When the key comes up, the solid fill drops and the tested tint remains, so you can walk the board once and see which keys have already answered. The count is only the keys drawn on this map, which is a full-size US layout: Escape, F1 through F12, the number row, letters, punctuation, both Shifts, both Controls, both Alts, both Command keys, Space, the arrows, and Insert, Delete, Home, End, Page Up and Page Down. A key that is not drawn, such as a media key or a numpad key on a full desktop keyboard, still updates the last-key line with its code, so you can confirm it arrived even though it has no square.

Left Shift and right Shift are separate tests

The layout draws Shift, Ctrl, Alt and Command twice because the browser reports them as different codes: ShiftLeft and ShiftRight, ControlLeft and ControlRight, AltLeft and AltRight, MetaLeft and MetaRight. Pressing one side does not mark the other. That is the useful case for a sticky or dead modifier: if the left Shift lights and the right one never does, the fault is that switch, not the letter keys that Shift is supposed to modify. Caps Lock is its own key, CapsLock, and it stays in the tested set after you release it even though the operating system also toggles the caps state. The letters on the map are the physical positions, QWERTY, not the character you get with Shift held. Holding Shift and pressing Digit2 still marks Digit2, while the last-key line shows @ on a US keyboard and a different character on another layout.

Keys the page is not allowed to see

Some presses never become a keydown in the page. The operating system takes them first: locking the screen, switching apps, changing brightness, or a browser shortcut that closes the tab. If you press one of those and both the map and the last-key line stay still, the test cannot tell a dead key from a shortcut that was swallowed. Try the same physical key in a context where it is just a character, or compare with the key beside it. Repeating a key by holding it down sets the repeat flag on later events, and the line says repeat, but the square only needs one successful press to count as tested. Switching away from the window clears the keys that were held down, so a stuck-looking highlight does not remain after you click another app.

How to use the marks when a key feels wrong

Click the page so it has focus, then press the suspect key once. If the square lights and the code matches the label, the browser received it and the problem is likely the app you were typing in, not the keyboard. If a neighbor lights and this one does not, and the last-key line never changes, that switch is not producing an event. Reset clears the tint, the last-key line and any key still marked down, so you can run the board again after reseating a cable or switching to another keyboard. The marks live only for this visit. Reloading the page starts from a blank map. Nothing you type is stored or sent.

Related tools

More: Fun & Games