Keycode Info
Press any key to see its JavaScript keyCode, key, code, which, and location event properties.
About This Tool
Keycode Info is an interactive tool for web developers working with keyboard events. Simply press any key on your keyboard and instantly see all the relevant JavaScript event properties: key, code, keyCode (deprecated but still widely used), which, location, and boolean modifier states (ctrlKey, shiftKey, altKey, metaKey).
Keyboard event handling is notoriously tricky in web development. The event.key property gives you the character produced, event.code gives the physical key location, and the legacy event.keyCode gives a numeric code. This tool shows all of these simultaneously so you can determine exactly which properties to use in your event handlers.
The tool also displays the event type (keydown, keypress, keyup), helps identify special keys like function keys and media keys, and shows how modifier combinations affect the output. It is invaluable for building keyboard shortcuts, game controls, accessibility features, and custom input handling.