Event code | Event key | Key code | Key name | Notes |
---|---|---|---|---|
Backspace | Backspace | 8 | backspace | |
Tab | Tab | 9 | tab | |
Enter | Enter | 13 | enter | |
ShiftLeft | Shift | 16 | shift(left) | `event.shiftKey` is true |
ShiftRight | Shift | 16 | shift(right) | `event.shiftKey` is true |
ControlLeft | Control | 17 | ctrl(left) | `event.ctrlKey` is true |
ControlRight | Control | 17 | ctrl(right) | `event.ctrlKey` is true |
AltLeft | Alt | 18 | alt(left) | `event.altKey` is true |
AltRight | Alt | 18 | alt(right) | `event.altKey` is true |
Pause | Pause | 19 | pause/break | |
CapsLock | CapsLock | 20 | caps lock | |
Escape | Escape | 27 | escape | |
Space | 32 | space | The `event.key` value is a single space. | |
PageUp | PageUp | 33 | page up | |
PageDown | PageDown | 34 | page down | |
End | End | 35 | end | |
Home | Home | 36 | home | |
ArrowLeft | ArrowLeft | 37 | left arrow | |
ArrowUp | ArrowUp | 38 | up arrow | |
ArrowRight | ArrowRight | 39 | right arrow | |
ArrowDown | ArrowDown | 40 | down arrow | |
PrintScreen | PrintScreen | 44 | print screen | |
Insert | Insert | 45 | insert | |
Delete | Delete | 46 | delete | |
Digit0 | 0 | 48 | 0 | |
Digit1 | 1 | 49 | 1 | |
Digit2 | 2 | 50 | 2 | |
Digit3 | 3 | 51 | 3 | |
Digit4 | 4 | 52 | 4 | |
Digit5 | 5 | 53 | 5 | |
Digit6 | 6 | 54 | 6 | |
Digit7 | 7 | 55 | 7 | |
Digit8 | 8 | 56 | 8 | |
Digit9 | 9 | 57 | 9 | |
KeyA | a | 65 | a | |
KeyB | b | 66 | b | |
KeyC | c | 67 | c | |
KeyD | d | 68 | d | |
KeyE | e | 69 | e | |
KeyF | f | 70 | f | |
KeyG | g | 71 | g | |
KeyH | h | 72 | h | |
KeyI | i | 73 | i | |
KeyJ | j | 74 | j | |
KeyK | k | 75 | k | |
KeyL | l | 76 | l | |
KeyM | m | 77 | m | |
KeyN | n | 78 | n | |
KeyO | o | 79 | o | |
KeyP | p | 80 | p | |
KeyQ | q | 81 | q | |
KeyR | r | 82 | r | |
KeyS | s | 83 | s | |
KeyT | t | 84 | t | |
KeyU | u | 85 | u | |
KeyV | v | 86 | v | |
KeyW | w | 87 | w | |
KeyX | x | 88 | x | |
KeyY | y | 89 | y | |
KeyZ | z | 90 | z | |
MetaLeft | Meta | 91 | left window key | `event.metaKey` is true |
MetaRight | Meta | 92 | right window key | `event.metaKey` is true |
ContextMenu | ContextMenu | 93 | select key (Context Menu) | |
Numpad0 | 0 | 96 | numpad 0 | |
Numpad1 | 1 | 97 | numpad 1 | |
Numpad2 | 2 | 98 | numpad 2 | |
Numpad3 | 3 | 99 | numpad 3 | |
Numpad4 | 4 | 100 | numpad 4 | |
Numpad5 | 5 | 101 | numpad 5 | |
Numpad6 | 6 | 102 | numpad 6 | |
Numpad7 | 7 | 103 | numpad 7 | |
Numpad8 | 8 | 104 | numpad 8 | |
Numpad9 | 9 | 105 | numpad 9 | |
NumpadMultiply | * | 106 | multiply | |
NumpadAdd | + | 107 | add | |
NumpadSubtract | - | 109 | subtract | |
NumpadDecimal | . | 110 | decimal point | |
NumpadDivide | / | 111 | divide | |
F1 | F1 | 112 | f1 | |
F2 | F2 | 113 | f2 | |
F3 | F3 | 114 | f3 | |
F4 | F4 | 115 | f4 | |
F5 | F5 | 116 | f5 | |
F6 | F6 | 117 | f6 | |
F7 | F7 | 118 | f7 | |
F8 | F8 | 119 | f8 | |
F9 | F9 | 120 | f9 | |
F10 | F10 | 121 | f10 | |
F11 | F11 | 122 | f11 | |
F12 | F12 | 123 | f12 | |
NumLock | NumLock | 144 | num lock | |
ScrollLock | ScrollLock | 145 | scroll lock | |
AudioVolumeMute | 173 | audio volume mute | ⚠️ The `event.which` value is 181 in Firefox. Also FF provides the code value as, `VolumeMute` | |
AudioVolumeDown | 174 | audio volume down | ⚠️ The `event.which` value is 182 in Firefox. Also FF provides the code value as, `VolumeDown` | |
AudioVolumeUp | 175 | audio volume up | ⚠️ The `event.which` value is 183 in Firefox. Also FF provides the code value as, `VolumeUp` | |
LaunchMediaPlayer | 181 | media player | ⚠️ The ️`event.which` value is 0(no value) in Firefox. Also FF provides the code value as, `MediaSelect` | |
LaunchApplication1 | 182 | launch application 1 | ⚠️ The ️`event.which` value is 0(no value) in Firefox. Also FF provides the code value as, `LaunchApp1` | |
LaunchApplication2 | 183 | launch application 2 | ⚠️ The ️`event.which` value is 0(no value) in Firefox. Also FF provides the code value as, `LaunchApp2` | |
Semicolon | ; | 186 | semi-colon | ⚠️ The `event.which` value is 59 in Firefox |
Equal | = | 187 | equal sign | ⚠️ The `event.which` value is 61 in Firefox |
Comma | , | 188 | comma | |
Minus | - | 189 | dash | ⚠️ The `event.which` value is 173 in Firefox |
Period | . | 190 | period | |
Slash | / | 191 | forward slash | |
Backquote | ` | 192 | Backquote/Grave accent | |
BracketLeft | [ | 219 | open bracket | |
Backslash | \ | 220 | back slash | |
BracketRight | ] | 221 | close bracket | |
Quote | ' | 222 | single quote |