Online Keyboard Tester

Quickly and easily test every key on your computer keyboard to ensure it's functioning correctly. Press any key to see it light up on the virtual keyboard below and view detailed information about the key event. Ideal for diagnosing sticky keys, unresponsive keys, or ghosting issues.

Keyboard Test Area

Loading virtual keyboard...

Last Key Event Details:

Key Value (event.key): -

Key Code (event.code): -

Numerical Code (event.which/keyCode): -

Pressed Keys Log:

Total Keys Pressed Count: 0

How to Use the Keyboard Tester

  1. Start Typing: Simply press any key on your physical keyboard.
  2. Visual Feedback: The corresponding key on the virtual keyboard displayed on this page will light up or change color to indicate it has been pressed.
  3. Key Event Details: Below the virtual keyboard, you'll see detailed information about the last key event:
    • Key Value (event.key): The actual character or name of the key (e.g., "a", "Enter", "Shift").
    • Key Code (event.code): The physical code of the key on the keyboard (e.g., "KeyA", "Enter", "ShiftLeft"). This is generally more consistent across different keyboard layouts for identifying the physical key.
    • Numerical Code (event.which/keyCode): Older numerical representations of the key (deprecated but shown for completeness).
  4. Pressed Keys Log: A running log records each key press with a timestamp and its event details. This log is scrollable.
  5. Total Keys Pressed: A counter shows the total number of keys pressed during your current test session.
  6. Reset Test: Click the "Reset Test & Clear Log" button at any time to clear all displayed information, the log, and the key press count, and to remove highlighting from the virtual keyboard.

Why Use an Online Keyboard Tester?

  • Diagnose Issues: Quickly identify if specific keys on your keyboard are malfunctioning, sticky, or not registering presses at all.
  • Check New Keyboards: Test a new keyboard to ensure all keys are working correctly before you start relying on it.
  • After Spills or Cleaning: If you've cleaned your keyboard or had an accidental spill, use this tool to verify that all keys are back in working order.
  • Ghosting/Jamming Test: By pressing multiple keys simultaneously, you can sometimes observe if your keyboard suffers from key ghosting (where some key presses are not registered when multiple keys are pressed) or jamming.
  • Understand Key Events: For developers or curious users, seeing the `event.key`, `event.code`, and `event.which` values can be informative for understanding how keyboard inputs are processed by web browsers.
  • No Installation Required: Test your keyboard directly in your browser without needing to download or install any software.

Frequently Asked Questions (FAQ)

What kind of keyboards can I test with this tool?

You can test most standard computer keyboards, including those for desktops (USB or wireless) and built-in laptop keyboards. The virtual keyboard displayed is based on a common US QWERTY layout, but the tool will register and display event information for keys pressed on other layouts as well (though the visual highlighting might map to the closest QWERTY equivalent if the `event.code` is standard).

Does this tool test mouse buttons or other input devices?

No, this tool is specifically designed for testing keyboard keys. It does not register or test mouse clicks or other input devices like game controllers.

Why do `event.key` and `event.code` sometimes show different values?

`event.code` typically represents the physical key pressed on the keyboard layout (e.g., `KeyQ` is the key where 'Q' is on a US-QWERTY layout). `event.key` represents the actual character value generated by that key press, which can be affected by modifier keys like Shift (e.g., pressing Shift + `KeyQ` might result in `event.key` being "Q" while `event.code` is still "KeyQ").

Is any of my keyboard input data stored or sent anywhere?

No. All key press detection and display happen entirely within your web browser (client-side). The key events are not sent to our servers or stored by us in any way. Your keyboard activity on this page is private to your current browser session. Please see our Privacy Policy for more details.