JavaScript Key Code Finder
Press any key to see its event.key, event.code, and legacy keyCode values.
Press any key…
Click here first if nothing happens
Runs locally in your browser. Keystrokes are not recorded or uploaded.
How to Use
- 1
Click the page
Make sure the tool has keyboard focus.
- 2
Press any key
All event values appear instantly, with modifiers and location.
- 3
Check recent keys
The history strip keeps the last dozen keys for comparison.
Frequently Asked Questions
- Open the tool and press any key — it instantly displays event.key, event.code, the legacy keyCode/which numbers, the key location, and any modifier keys held.
Related Tools
CSS FormatterMinify or beautify CSS stylesheetsJS FormatterMinify or beautify JavaScript codeHTML FormatterBeautify or minify HTML markupHTML EscapeEscape special HTML characters to entitiesHTML StripperRemove all HTML tags to extract plain textHTML EntitiesSearchable reference for all HTML entity codesSQL FormatterBeautify and format SQL queriesXML FormatterFormat, validate, and minify XML documents instantly