⌨️ Keyboard Event Tester

Real-time keyboard event . Display key presses, modifier keys, and keyboard event logs. Perfect for debugging keyboard shortcuts and interactions. | No Signup, Client-Side · No Server Uploads

Zero Dependencies·Works Offline
Press any key
Ctrl
Alt
Shift
Meta
event.key
-
event.code
-
event.type
-
event.repeat
-
TypekeycodeModifiers

What is a Keyboard Event Tester?

A keyboard event tester is a developer tool that captures and displays keyboard event details in real-time. When you press a key, the tool instantly shows event.key, event.code, event type, modifier key states, and key repeat information - all from the browser native KeyboardEvent API.

Why Use a Keyboard Event Tester?

Understanding keyboard events is essential for building accessible web applications. This tool helps you debug keyboard shortcut implementations, test key behavior across layouts, understand event.key vs event.code differences, and verify modifier key combinations.

About the KeyboardEvent API

The KeyboardEvent interface describes keyboard interactions. It fires two main event types: keydown (key pressed) and keyup (key released). Key properties include key (character value), code (physical key position), ctrlKey/altKey/shiftKey/metaKey (modifier states), and repeat (auto-repeat).

FAQ

What can this tool do?

Real-time display of keyboard events: event.key, event.code, event type (keydown/keyup), modifier states (Ctrl/Alt/Shift/Meta), and repeat status.

How to test keyboard shortcuts?

Press modifier keys together with other keys. The tool shows all active modifiers and the combined key information in real-time.

What is the difference between event.key and event.code?

event.key returns the character value (e.g. "a", "Enter"), while event.code returns the physical key location (e.g. "KeyA", "Enter") which does not change with keyboard layout.

How many log entries are kept?

Up to 50 recent keyboard events are kept. Click "Clear Log" to reset.

Why do some keys not show up?

The tool ignores key events in input fields to avoid interference. Click anywhere on the page to activate keyboard capture.

Keyboard Event Tester | No Signup, Client-Side · No Server Uploads

Feedback: dexshuang@google.com