A simple template that makes it easier to see that a keyboard key is involved. Use {{key combo}} if two or more keys need to be pressed at the same time instead of this template.
Usage
{{Key press|key|border style}}
- key is the literal name of the key to be pressed. For F4, for example, the syntax is
{{Key press|F4}}
. This results in the following: F4
- HTML character entities are allowed. For example, to display the multiplication symbol, this works:
{{Key press|×}}
and results in ×.
- To display a pressed key, add
inset
border style like this: {{Key press|F4|inset}}
and the key will appear to be pressed: F4.
- The key and border parameters can be reversed, but then their names need to be specified:
{{Key press|border=inset|key=F4}}
will become F4
- Forgetting to specify a key will default to the equals sign:
{{Key press}}
becomes =.
Common keys
For ease of use and consistency throughout pages, the code for some common multi-letter keys is provided here, ready to be copied and pasted into articles. Symbols rely on UTF-8 support by the browser and a font that contains the glyph, so for best compatibility, the text-only version of the code can be recommended for use in most articles. Not every key has a corresponding symbol.
Cursor control
Key
|
Text
|
Symbol
|
Symbol with text
|
Text with symbol
|
Left
|
- Left
{{Key press|Left}}
|
- ←
{{Key press|←}}
{{Key press|←}}
{{Key press|←}}
|
- ← Left
{{Key press|← Left}}
{{Key press|← Left}}
{{Key press|← Left}}
|
- Left ←
{{Key press|Left ←}}
{{Key press|Left ←}}
{{Key press|Left ←}}
|
Up
|
- Up
{{Key press|Up}}
|
- ↑
{{Key press|↑}}
{{Key press|↑}}
{{Key press|↑}}
|
- ↑ Up
{{Key press|↑ Up}}
{{Key press|↑ Up}}
{{Key press|↑ Up}}
|
- Up ↑
{{Key press|Up ↑}}
{{Key press|Up ↑}}
{{Key press|Up ↑}}
|
Right
|
- Right
{{Key press|Right}}
|
- →
{{Key press|→}}
{{Key press|→}}
{{Key press|→}}
|
- → Right
{{Key press|→ Right}}
{{Key press|→ Right}}
{{Key press|→ Right}}
|
- Right →
{{Key press|Right →}}
{{Key press|Right →}}
{{Key press|Right →}}
|
Down
|
- Down
{{Key press|Down}}
|
- ↓
{{Key press|↓}}
{{Key press|↓}}
{{Key press|↓}}
|
- ↓ Down
{{Key press|↓ Down}}
{{Key press|↓ Down}}
{{Key press|↓ Down}}
|
- Down ↓
{{Key press|Down ↓}}
{{Key press|Down ↓}}
{{Key press|Down ↓}}
|
Modifier keys
Key
|
Text
|
Symbol
|
Symbol with text
|
Text with symbol
|
Shift
|
- Shift
{{Key press|Shift}}
|
- ⇧
{{Key press|⇧}}
{{Key press|⇧}}
|
- ⇧ Shift
{{Key press|⇧ Shift}}
{{Key press|⇧ Shift}}
|
- Shift ⇧
{{Key press|Shift ⇧}}
{{Key press|Shift ⇧}}
|
Control
|
- Ctrl
{{Key press|Ctrl}}
|
- ^
{{Key press|^}}
|
- ^ Ctrl
{{Key press|^ Ctrl}}
|
- Ctrl ^
{{Key press|Ctrl ^}}
|
Command
|
- Command
{{Key press|Command}}
|
- ⌘
{{Key press|⌘}}
{{Key press|⌘}}
|
- ⌘ Command
{{Key press|⌘ Command}}
{{Key press|⌘ Command}}
|
- Command ⌘
{{Key press|Command ⌘}}
{{Key press|Command ⌘}}
|
Option
|
- Option
{{Key press|Option}}
|
- ⌥
{{Key press|⌥}}
{{Key press|⌥}}
|
- ⌥ Option
{{Key press|⌥ Option}}
{{Key press|⌥ Option}}
|
- Option ⌥
{{Key press|Option ⌥}}
{{Key press|Option ⌥}}
|
Alt
|
- Alt
{{Key press|Alt}}
|
|
|
|
Alt Graph
|
- AltGr
{{Key press|AltGr}}
|
|
|
|
Other often-used keys
Key
|
Text
|
Symbol
|
Symbol with text
|
Text with symbol
|
Space
|
- Space
{{Key press|Space}}
|
- ⎵
{{Key press|⎵}}
{{Key press|⎵}}
|
- ⎵ Space
{{Key press|⎵ Space}}
{{Key press|⎵ Space}}
|
- Space ⎵
{{Key press|Space ⎵}}
{{Key press|Space ⎵}}
|
Enter
|
- Enter
{{Key press|Enter}}
|
- ↵
{{Key press|↵}}
{{Key press|↵}}
{{Key press|↵}}
- ⌤
{{Key press|⌤}}
{{Key press|⌤}}
|
- ↵ Enter
{{Key press|↵ Enter}}
{{Key press|↵ Enter}}
{{Key press|↵ Enter}}
- ⌤ Enter
{{Key press|⌤ Enter}}
{{Key press|⌤ Enter}}
|
- Enter ↵
{{Key press|Enter ↵}}
{{Key press|Enter ↵}}
{{Key press|Enter ↵}}
- Enter ⌤
{{Key press|Enter ⌤}}
{{Key press|Enter ⌤}}
|
Tab
|
- Tab
{{Key press|Tab}}
|
- ↹
{{Key press|↹}}
{{Key press|↹}}
- ⭾ (better, but less compatible)
{{Key press|⭾}}
{{Key press|⭾}}
|
- ↹ Tab
{{Key press|↹ Tab}}
{{Key press|↹ Tab}}
- ⭾ Tab
{{Key press|⭾ Tab}}
{{Key press|⭾ Tab}}
|
- Tab ↹
{{Key press|Tab ↹}}
{{Key press|Tab ↹}}
- Tab ⭾
{{Key press|Tab ⭾}}
{{Key press|Tab ⭾}}
|
Escape
|
- Esc
{{Key press|Esc}}
|
- ⎋
{{Key press|⎋}}
{{Key press|⎋}}
|
- ⎋ Esc
{{Key press|⎋ Esc}}
{{Key press|⎋ Esc}}
|
- Esc ⎋
{{Key press|Esc ⎋}}
{{Key press|Esc ⎋}}
|