Skip to content

Keyboard Shortcuts Reference

This comprehensive reference covers all keyboard shortcuts for both Cursor IDE and Claude Code, helping you work efficiently with AI-powered development tools.

Most Essential Shortcuts

  • Ctrl+K / Cmd+K - Inline Edit
  • Ctrl+I / Cmd+I - Agent Chat
  • Tab - Accept autocomplete
  • Ctrl+E / Cmd+E - Background Agent
  • Escape - Cancel operation
ShortcutActionWindows/LinuxmacOS
Toggle SidepanelOpen/close AI chatCtrl+ICmd+I
Toggle Sidepanel (alt)Open/close AI chatCtrl+LCmd+L
Background AgentControl panelCtrl+ECmd+E
Mode MenuChange AI modesCtrl+.Cmd+.
Model SwitchingLoop between modelsCtrl+/Cmd+/
Cursor SettingsOpen Cursor settingsCtrl+Shift+JCmd+Shift+J
General SettingsVS Code settingsCtrl+,Cmd+,
Command PaletteAll commandsCtrl+Shift+PCmd+Shift+P
ShortcutActionWindows/LinuxmacOS
SubmitSend messageEnterEnter
Force SubmitOverride queueAlt+EnterAlt+Enter
Cancel GenerationStop AI responseCtrl+Shift+BackSpaceCmd+Shift+BackSpace
Add Code ContextSelected code to chatCtrl+Shift+LCmd+Shift+L
Paste as ContextAdd clipboardCtrl+VCmd+V
Paste to InputAdd to messageCtrl+Shift+VCmd+Shift+V
Accept All ChangesApply suggestionsCtrl+EnterCmd+Enter
Reject All ChangesDiscard suggestionsCtrl+BackSpaceCmd+BackSpace
Next MessageNavigate forwardTabTab
Previous MessageNavigate backShift+TabShift+Tab
Model ToggleSwitch modelsCtrl+Alt+/Cmd+Alt+/
New ChatStart freshCtrl+N or Ctrl+RCmd+N or Cmd+R
New Chat TabNew tabCtrl+TCmd+T
Previous ChatHistory backCtrl+[Cmd+[
Next ChatHistory forwardCtrl+]Cmd+]
Close ChatEnd conversationCtrl+WCmd+W
Unfocus FieldExit inputEscEsc
ShortcutActionWindows/LinuxmacOS
Open Inline EditStart editingCtrl+KCmd+K
Toggle FocusSwitch input focusCtrl+Shift+KCmd+Shift+K
Submit EditApply changesEnterEnter
Cancel EditDiscard changesCtrl+Shift+BackSpaceCmd+Shift+BackSpace
Quick QuestionAsk about selectionAlt+EnterAlt+Enter
ShortcutActionWindows/LinuxmacOS
@ SymbolsReference symbols@@
FilesReference files##
CommandsSlash commands//
Add to ChatSelection to chatCtrl+Shift+LCmd+Shift+L
Add to EditSelection to inlineCtrl+Shift+KCmd+Shift+K
New Chat with SelectionStart fresh chatCtrl+LCmd+L
Toggle Reading StrategyChange file readingCtrl+MCmd+M
Accept Next WordPartial acceptCtrl+Arrow-RightCmd+Arrow-Right
Search CodebaseSemantic searchCtrl+EnterCmd+Enter
ShortcutActionWindows/LinuxmacOS
Accept SuggestionComplete codeTabTab
Accept Next WordPartial completionCtrl+Arrow-RightCmd+Arrow-Right
Reject SuggestionDismissEscEsc
ShortcutActionWindows/LinuxmacOS
Terminal PromptAI command generationCtrl+KCmd+K
Run CommandExecute generatedCtrl+EnterCmd+Enter
Accept CommandConfirm commandEscEsc
ShortcutActionWindows/LinuxmacOS
Show All ShortcutsView complete listCtrl+R then Ctrl+SCmd+R then Cmd+S
AI Commit MessageGenerate commit msgConfigurableConfigurable
Copy Code ReferenceWith contextCtrl+CCmd+C
Paste Code ReferenceAs contextCtrl+VCmd+V
Paste Code as TextWithout referenceCtrl+Shift+VCmd+Shift+V
ShortcutDescriptionContext
Ctrl+CCancel current input/generationStandard interrupt
Ctrl+DExit Claude Code sessionEOF signal
Ctrl+LClear terminal screenKeeps conversation history
Up/Down arrowsNavigate command historyRecall previous inputs
Esc + EscEdit previous messageDouble-escape to modify
TabCommand completionAutocomplete commands
MethodShortcutContext
Quick escape\ + EnterWorks in all terminals
macOS defaultOption+EnterDefault on macOS
Terminal setupShift+EnterAfter /terminal-setup
Paste modeDirect pasteFor code blocks, logs
ShortcutDescriptionNotes
# at startMemory shortcut - add to CLAUDE.mdPrompts for file selection
/ at startSlash command menuSee slash commands section
@ in messageReference filesInclude file contents

Enable with /vim command or configure permanently via /config.

CommandActionFrom mode
EscEnter NORMAL modeINSERT
iInsert before cursorNORMAL
IInsert at beginning of lineNORMAL
aInsert after cursorNORMAL
AInsert at end of lineNORMAL
oOpen line belowNORMAL
OOpen line aboveNORMAL
CommandAction
h/j/k/lMove left/down/up/right
wNext word
eEnd of word
bPrevious word
0Beginning of line
$End of line
^First non-blank character
ggBeginning of input
GEnd of input
CommandAction
xDelete character
ddDelete line
DDelete to end of line
dw/de/dbDelete word/to end/back
ccChange line
CChange to end of line
cw/ce/cbChange word/to end/back
.Repeat last change
KeyFunctionImportant Note
EscapeStop Claude operationNot Ctrl+C (exits entirely)
Escape twiceShow message listJump to any previous message
Control+VPaste imagesNot Command+V on Mac
#Quick CLAUDE.md updateDynamic documentation
Up arrowPrevious commandsWorks across sessions

macOS Users

  • Use Cmd instead of Ctrl for most shortcuts
  • Claude Code image paste: Ctrl+V (not Cmd+V)
  • Terminal line breaks: Option+Enter by default
  • VS Code import: Same keybindings work

Windows/Linux Users

  • Ctrl is the primary modifier key
  • Some terminal emulators may capture shortcuts
  • Configure terminal for proper Shift+Enter support
  • Check for conflicts with system shortcuts
  1. For line breaks in Claude Code

    • Run /terminal-setup for automatic configuration
    • Or manually set up Shift+Enter in your terminal
  2. For better Claude Code experience

    • Disable conflicting terminal shortcuts
    • Enable proper escape key handling
    • Configure history navigation
  3. For IDE integration

    • Install appropriate extensions
    • Configure launch shortcuts
    • Set up proper terminal profiles
  1. Open Keyboard Shortcuts: Ctrl+R then Ctrl+S
  2. Search for the command you want to modify
  3. Click the pencil icon to edit
  4. Press your desired key combination
  5. Save changes

Example custom binding for AI commit message:

{
"key": "cmd+m",
"command": "cursor.generateGitCommitMessage"
}

Create shortcuts for frequently used commands:

  1. Create .claude/commands/ directory
  2. Add markdown files for custom commands
  3. Use / to access your commands

Example: .claude/commands/review.md:

Please review this code for bugs and security issues.
Focus on potential vulnerabilities and logic errors.
  1. Quick Fix: Select code → Ctrl+K → describe fix
  2. Add Context: Ctrl+Shift+L → ask question
  3. Multi-file: @ multiple files → Ctrl+I
  4. Fast Accept: TabCtrl+Arrow for partial

For Cursor:

  • Bind frequently used AI features to custom shortcuts
  • Use @ symbols extensively for context
  • Master the Tab key for rapid completion
  • Keep chat tabs organized with Ctrl+T

For Claude Code:

  • Use # for quick documentation updates
  • Master escape key for flow control
  • Leverage command history with up arrow
  • Create custom slash commands for repetitive tasks

Cursor Issues

  • Shortcuts not working: Check for extension conflicts
  • Wrong model selected: Use Ctrl+/ to cycle
  • Chat not responding: Try Ctrl+Shift+BackSpace
  • Context missing: Verify with @ symbol references

Claude Code Issues

  • Escape not working: Check terminal settings (especially JetBrains)
  • Can’t paste images: Use Ctrl+V, not Cmd+V on Mac
  • Line breaks difficult: Run /terminal-setup
  • History not working: Ensure proper shell configuration

Print this section for desk reference:

  1. Ctrl/Cmd+K - Inline Edit
  2. Ctrl/Cmd+I - Agent Chat
  3. Tab - Accept suggestion
  4. Ctrl/Cmd+Shift+L - Add to chat
  5. Ctrl/Cmd+E - Background Agent
  6. @ - Reference symbols
  7. Ctrl/Cmd+/ - Switch models
  8. Ctrl/Cmd+Enter - Accept all
  9. Escape - Cancel
  10. Ctrl/Cmd+Shift+P - Command palette
  1. Escape - Stop Claude
  2. Escape twice - Edit message
  3. Up arrow - Previous command
  4. Tab - Complete command
  5. # - Update CLAUDE.md
  6. / - Slash commands
  7. @ - Reference files
  8. Ctrl+V - Paste images
  9. \ + Enter - New line
  10. Ctrl+D - Exit session