Contextual Shortcuts

Contextual shortcuts is an AI UX pattern that surfaces keyboard or palette actions relevant to the current task, such as design tools in canvas mode versus document tools in text mode. The shortcut set adapts instead of staying static, and changes should be visible in the cheatsheet overlay.

Interactive demo

Contextual Shortcuts
Open command palette
Anywhere
⌘K

Overview

The design problem

How might we design contextual shortcuts so people can trust and act on AI output?

Use this pattern

When this pattern fits

  • Perfect for productivity tools, power-user applications, and platforms where context-aware shortcuts improve workflow efficiency and discoverability.

Avoid this pattern

When to skip or lighten it

  • Changing shortcuts mid-task without showing the new map.
  • Mobile products with no hardware keyboard.
  • Contexts where muscle memory needs fixed bindings.

States

State model coming soon

Key UX elements

Key UX elements coming soon

Anti-patterns to avoid

  • Rebinding keys silently when context switches.

  • Cheatsheet that lists every shortcut with no filter.

  • AI-suggested shortcuts with no confirm before bind.

  • Conflicts with OS shortcuts unmarked.

How products use it

ProductImplementation
VS CodeWhen clauses on keybindings by editor language and view.
FigmaTool-specific shortcuts while editing vs presenting.
NotionSlash menu and shortcuts change by block type.
LinearIssue view shortcuts vs inbox view shortcuts.

Implementation

Copy this prompt to generate a production-ready implementation in Cursor, Claude Code, Lovable, or any AI coding agent.

Generate a production-ready implementation of the "Contextual Shortcuts" AI interface design pattern.

Pattern Definition:

Frequently asked questions

Show shortcuts how?

Hold modifier to reveal overlay, or context panel listing only active bindings.

Contextual shortcuts vs command history?

Shortcuts are keys for actions. Command history replays past AI commands.

Customization?

Let power users pin favorites across contexts.

AI role?

Rank which shortcuts to promote based on task, not invent new keys silently.

Weekly AI UX in your inbox

Weekly AI interface UX notes and resources on Substack, no spam, unsubscribe anytime.

Subscribe on Substack