Context menu
Definition
A context menu offers actions related to a selected element or the current situation.
A context menu appears, for example, after right-clicking on a file or page element. Its entries depend on the respective context. Keyboard operation can also be provided; important functions should not be accessible only via a hard-to-discover gesture.
Simply explained
You open a small menu on an item and see exactly what you can do with it.
Why it matters in practice
Context-related actions keep interfaces clear and can make frequent tasks directly accessible on the affected object.
Example from business
Possible example: A file manager offers the actions Rename, Download, and Move for a selected document.
Limits and pitfalls
- Hidden actions are hard to find. A dedicated menu must be easy to use and must not unintentionally block familiar browser functions.
Origin & history
Context menus belong to graphical user interfaces; on the web, the contextmenu event can indicate their request by mouse or keyboard.
Use in mid-sized companies
- Businesses can bundle object actions in internal applications and additionally offer important functions via visible controls.
Frequently asked questions
Do you always need a mouse for this?
No. Depending on the application, a context menu can also be opened via the keyboard.
Sources
- Element: contextmenu event. · MDN (2026): Element: contextmenu event.
Editorially reviewed on: