How do I use the keycode tester?
Click the big box so it has focus, then press any key. The box shows the key in large type, and the panels beside it show event.key, event.code, keyCode, which, the key location, and whether Ctrl, Alt, Shift or Meta were held. Try combinations like Ctrl + K or Shift + A. Your last 12 keys are kept in the history, and Copy event puts the full details on your clipboard for use in code or bug reports.
key vs code vs keyCode — what is the difference?
event.key is the character or named key the press produces ("a", “A” with Shift, “Enter”, “ArrowLeft”) — it changes with keyboard layout and modifiers. event.code names the physical key position ("KeyA", “Digit1”, “Space”) and stays the same on every layout, which makes it ideal for games. keyCode and which are legacy numeric values (A=65, Enter=13) from before these properties existed; they are deprecated but still appear in older code, so this tool shows them for reference.
What are modifier keys and location?
Modifiers are Ctrl, Alt, Shift and Meta (the Windows or Command key). Shortcuts are built from them: Ctrl + S, Alt + Tab, Cmd + K. Location tells you which copy of a duplicated key was pressed: Left or Right for Shift/Ctrl/Alt pairs, Numpad for the numeric keypad, and Standard for everything else. Games and shortcut systems use location to treat left and right Shift as different keys.
Why do developers need keycodes?
Keyboard shortcuts in web apps (press “/” to search, Esc to close), game controls (WASD movement), accessibility features, form handling (Enter to submit), and debugging “my shortcut does not work on a French keyboard” reports — all of these start with knowing what the browser actually received. A keycode tester is the fastest way to check, without writing a line of code.
Common keycodes reference
Enter=13, Escape=27, Space=32, Backspace=8, Tab=9, Delete=46. Arrow keys: Left 37, Up 38, Right 39, Down 40. Letters A–Z are 65–90 and digits 0–9 are 48–57 in keyCode terms. Function keys F1–F12 are 112–123. Remember that modern code should prefer event.key and event.code — use these numbers only when maintaining legacy code.
Is it free and private?
Yes. The keycode tester is completely free, needs no sign-up, and runs entirely in your browser. Key presses are processed locally and never uploaded or stored — safe even for testing password-style combinations (though you should never type a real password into any tool). It works on phones with external keyboards, tablets and desktop computers.