Loading your tools...
Loading your tools...
Find the javascript keycode, code, location and modifiers of any pressed key.
Press the key on your keyboard you want to get info about this key
Press any key to see javascript keycode, code, location and modifiers
Click or focus the capture area, then press any key on your keyboard.
View Key (character), Keycode (numeric), Code (physical key), Location (0–3), and Modifiers (Shift, Ctrl, Alt, Meta).
Copy any value with the copy button for use in your code.
keycode info html: Find key codes for HTML onkeydown, onkeypress handlers
javascript keycode list: Build keyboard shortcuts, detect Escape (27), Enter (13)
event keycode: Debug KeyboardEvent.keyCode in React, Vue, vanilla JS
keycode tester: Test modifier combinations (Ctrl+Shift, Meta+Key)
keyboard key codes: Reference for games, accessibility, form validation
Keycode info displays JavaScript KeyboardEvent properties: key (character value), keyCode (deprecated but still used), code (physical key like KeyA, ShiftLeft), location (0=standard, 1=left, 2=right, 3=numpad), and modifiers (Shift, Ctrl, Alt, Meta). Use this keycode tester for keycode online lookup. keyboard key codes, event keycode, javascript keycode list. keycode info html for onkeydown. Free keycode generator for developers.
keyCode is deprecated—prefer key and code for new code. But many codebases still use keyCode; this tool shows both.
Escape: 27, Enter: 13, Tab: 9, Space: 32, Backspace: 8. Modifiers: Shift 16, Ctrl 17, Alt 18, Meta 91 (Windows) or 224 (Mac). Letters A–Z: 65–90. Use this keycode tester to verify.
For keycode info html use onkeydown/onkeyup. For addEventListener, pass (event) => { console.log(event.keyCode, event.code) }. This tool provides a keycode list for any key.