JavaScript Keycode Inspector - Inspect Keyboard Event Codes Online
Press any key on your keyboard to instantly inspect JavaScript event.key, event.code, event.keyCode, and modifier key states.
This tool runs in your browser.
Focus the field and press any key.
Processed locally in your browser.
How to use
- 01Enter or upload the source data.
- 02Run the tool in your browser.
- 03Review, copy, or download the result.
FAQ
Why is event.code preferred over deprecated event.keyCode?
The W3C deprecated keyCode due to platform-specific discrepancies. event.code reliably indicates physical key location regardless of active keyboard layout.
Does the inspector track combination shortcuts like Ctrl+Shift?
Yes. Visual indicators reflect the instantaneous state of modifier keys including Shift, Control, Alt, and Meta/Command.
Does this tool log or transmit my keystrokes?
No. Event listeners execute client-side purely inside your browser window without transmitting or logging keystroke sequences.