Keyboard Tester

Free online keyboard tester.

Active Keys
0
Last Key
-
Code
-
KeyCode
-
Esc
1
2
3
4
5
6
7
8
9
0
-
=
Del
Tab
Q
W
E
R
T
Y
U
I
O
P
[
]
Caps
A
S
D
F
G
H
J
K
L
;
'
Enter
Shift
Z
X
C
V
B
N
M
,
.
/
Shift
Ctrl
Alt
Space
Alt
Ctrl
Press any key on your physical keyboard to test it

What Is the Keyboard Tester?

A keyboard tester is a diagnostic tool that lets you verify every key on your keyboard is functioning correctly. As you press each key, the corresponding key on the visual on-screen keyboard lights up, confirming that the key press was registered by your system. The tool also displays the key name, code, and keyCode of the last pressed key, which is useful for developers and gamers who need to identify specific key codes for bindings. Additionally, the tester can help detect ghosting issues — situations where pressing multiple keys simultaneously causes some keys to not register — which is a limitation of non-gaming keyboards.

How It Works

The tool listens for keydown and keyup events at the browser level. When a key is pressed, the event includes the key property (the character produced), the code property (the physical key identifier, such as KeyA or Space), and the keyCode property (a legacy numeric code). The on-screen keyboard highlights the pressed key using its code property, which maps to a physical key position rather than a character, making the layout consistent regardless of keyboard language or layout settings.

How to Use

  1. Click on the page or press any key to focus the test.
  2. Press any key on your physical keyboard.
  3. The corresponding key on the visual keyboard will light up.
  4. The last pressed key, code, and keyCode are displayed in the stats bar.
  5. Press multiple keys simultaneously to test for ghosting.
  6. Use Reset to clear the visual state.

Tips & Information

Test Every Key

Systematically press every key on your keyboard, starting from the top-left (Escape) and working across each row. This ensures no key is missed. If a key does not light up, it may be faulty or there may be a software conflict.

Ghosting vs N-Key Rollover

Press 6 or more keys at once. If some keys do not register, your keyboard has ghosting limitations. Gaming keyboards with N-key rollover (NKRO) can register all keys simultaneously. Non-gaming keyboards typically support only 3 to 6 simultaneous keys.

Check Modifier Keys

Do not forget to test modifier keys (Shift, Ctrl, Alt, Caps Lock, Tab, Space, Enter). These are essential for keyboard shortcuts and are often the first to develop issues due to heavy use.

Test in Different Browsers

If a key is not registering, try a different browser. Some browsers intercept certain key combinations (like Ctrl+W or F5) before they reach the page. Using a different browser can help isolate whether the issue is hardware or software.

Frequently Asked Questions

Why does a key not light up when I press it?

The key may be physically faulty, the browser may be intercepting it (common with function keys and shortcuts), or there may be a driver issue. Try a different browser and a different application to isolate the cause.

What is keyboard ghosting?

Ghosting is when a keyboard fails to register certain key combinations because of its circuit matrix design. If you press multiple keys and some do not appear, your keyboard has ghosting. Gaming keyboards with NKRO avoid this.

What is the difference between key and code?

The key property represents the character produced (which changes with keyboard layout), while code represents the physical key position (which stays the same regardless of layout). For example, pressing the Q key on a QWERTY layout produces key="q" and code="KeyQ".

Does this work with non-English keyboards?

Yes. The visual layout is based on the standard US QWERTY layout, but the code property maps to physical key positions, so keys will light up correctly regardless of your keyboard layout. The displayed key character will reflect your active layout.

Can I test laptop keyboards?

Yes, the tool works with any keyboard that the operating system recognizes, including laptop keyboards, external USB keyboards, and Bluetooth keyboards.

Why is keyCode showing 0 for some keys?

keyCode is a deprecated property and may return 0 for certain keys in modern browsers, especially on macOS. This is expected behavior — use the code property instead for reliable key identification.

Related Tools