PowerShell keyboard shortcuts

PowerShell is Microsoft's command shell and scripting language, and its line editing comes from a module called PSReadLine. These keys move the cursor, edit the line, search history, complete commands, and select text, including Vi mode.

Windows, macOS, Linux · 62 shortcuts

Cursor movement

Move by character, word, line, page, brace, or numeric argument while editing the current PowerShell command.

ActionShortcuts
Move left one characterCtrl+B is the Emacs binding; Left works in Windows and Vi insert modes.
Windows / macOS / LinuxLeftorCtrl + B
Move right one characterCtrl+F is the Emacs binding; Right works in Windows and Vi insert modes.
Windows / macOS / LinuxRightorCtrl + F
Move back one wordAlt+B is the Emacs binding. Vi insert and command modes also use Ctrl+Left.
Windows / macOS / LinuxCtrl + LeftorAlt + B
Move forward one wordAlt+F is the Emacs binding.
Windows / macOS / LinuxCtrl + RightorAlt + F
Move to the start of the line
Windows / macOS / LinuxHomeorCtrl + A
Move to the end of the line
Windows / macOS / LinuxEndorCtrl + E
Move to the start of the input
Windows / macOS / LinuxCtrl + Home
Move to the end of the input
Windows / macOS / LinuxCtrl + End
Go to the matching brace, parenthesis, or bracket
Windows / macOS / LinuxCtrl + ]
Move to the first non-blank characterVi command mode; underscore is an alternative.
Windows / macOS / Linux^
Start a numeric argument for the next actionAlt+0 through Alt+9 and Alt+- set the argument in Windows and Emacs modes.
Windows / macOS / LinuxAlt + 0

Editing the command line

Delete, insert, transform, transpose, accept, or cancel text before PowerShell evaluates the command.

ActionShortcuts
Delete the character before the cursorCtrl+H is the Emacs binding.
Windows / macOS / LinuxBackspaceorCtrl + H
Delete the character under the cursor
Windows / macOS / LinuxDelete
Delete a character, or exit on an empty lineEmacs mode.
Windows / macOS / LinuxCtrl + D
Delete the previous word into the kill ringCtrl+Backspace and Ctrl+W are Windows mode; Alt+Backspace and Escape+Backspace are Emacs mode.
Windows / macOS / LinuxCtrl + BackspaceorCtrl + WorAlt + Backspace
Delete the next word into the kill ringAlt+D is Windows and Emacs mode; Ctrl+Delete is also bound in Windows and Vi modes.
Windows / macOS / LinuxAlt + DorCtrl + Delete
Delete from the start of input to the cursorEmacs mode; Ctrl+X then Backspace is an alternative.
Windows / macOS / LinuxCtrl + U
Delete from the cursor to the end of inputEmacs mode.
Windows / macOS / LinuxCtrl + K
Delete from the cursor to the end of input without the kill ringWindows and Vi insert modes.
Windows / macOS / LinuxCtrl + End
Copy the selected region, or the whole lineWindows mode. In Emacs mode Ctrl+C copies when text is selected or cancels the line otherwise.
Windows / macOS / LinuxCtrl + C
Cut the selected regionWindows mode.
Windows / macOS / LinuxCtrl + X
Paste from the system clipboardWindows mode; Vi insert mode uses Ctrl+V.
Windows / macOS / LinuxCtrl + VorShift + Insert
Undo the previous editCtrl+Z is Windows and Vi mode; the alternatives are Emacs mode.
Windows / macOS / LinuxCtrl + ZorCtrl + _orCtrl + X then Ctrl + U
Redo an undone editWindows and Vi modes.
Windows / macOS / LinuxCtrl + Y
Swap the current character with the previous oneEmacs and Vi insert modes.
Windows / macOS / LinuxCtrl + T
Capitalize the next wordEmacs mode. Escape+C is an alternative.
Windows / macOS / LinuxAlt + C
Convert the next word to uppercaseEmacs mode. Escape+U is an alternative.
Windows / macOS / LinuxAlt + U
Convert the next word to lowercaseEmacs mode. Escape+L is an alternative.
Windows / macOS / LinuxAlt + L
Accept and run the current line
Windows / macOS / LinuxEnterorCtrl + M
Insert a blank line aboveWindows mode.
Windows / macOS / LinuxCtrl + Enter
Insert a blank line belowWindows mode.
Windows / macOS / LinuxCtrl + Shift + Enter
Insert a new line in multiline input
Windows / macOS / LinuxShift + Enter

History

Recall, search, clear, and move through PowerShell history without retyping commands you already composed.

ActionShortcuts
Load the previous history entryCtrl+P is the Emacs alternative. Vi command mode also supports K and minus.
Windows / macOS / LinuxUporCtrl + P
Load the next history entryCtrl+N is the Emacs alternative. Vi command mode also supports J and plus.
Windows / macOS / LinuxDownorCtrl + N
Find the previous history entry matching the current prefixWindows mode.
Windows / macOS / LinuxF8
Find the next history entry matching the current prefixWindows mode.
Windows / macOS / LinuxShift + F8
Move to the first history itemEmacs mode.
Windows / macOS / LinuxAlt + <
Move to the current input at the end of historyEmacs mode.
Windows / macOS / LinuxAlt + >
Clear PSReadLine historyWindows mode. This does not clear PowerShell's persisted history.
Windows / macOS / LinuxAlt + F7

Completion and display

Complete commands, show a menu of possible completions, inspect parameter help, clear the screen, and capture text.

ActionShortcuts
Complete the text around the cursorEmacs mode. Windows mode uses Tab for TabCompleteNext.
Windows / macOS / LinuxTab
Display possible completionsAlt+= is Emacs mode; Ctrl+Space is Vi insert and command mode.
Windows / macOS / LinuxAlt + =orCtrl + Space
Select the next completionWindows mode and Vi command mode.
Windows / macOS / LinuxTab
Select the previous completionWindows mode and Vi insert or command mode.
Windows / macOS / LinuxShift + Tab
Show dynamic parameter help
Windows / macOS / LinuxAlt + H
Clear the screen and redraw the current line
Windows / macOS / LinuxCtrl + L
Start interactive screen captureThe function is unbound by default. Bind it with Set-PSReadLineKeyHandler if you need it.
Windows / macOS / LinuxNot documented

Selection and Vi mode

Select text, move through visual ranges, and use the mode-specific bindings that only appear in PSReadLine's Vi command layer.

ActionShortcuts
Select one character left
Windows / macOS / LinuxShift + Left
Select one character right
Windows / macOS / LinuxShift + Right
Select to the end of the line
Windows / macOS / LinuxShift + End
Select the next wordWindows mode.
Windows / macOS / LinuxShift + Ctrl + Right
Extend selection by the next wordEmacs mode.
Windows / macOS / LinuxAlt + F
Set a mark at the cursorEmacs mode.
Windows / macOS / LinuxCtrl + @
Switch from Vi insert to Vi command modeVi mode.
Windows / macOS / LinuxEsc
Delete the current lineVi command mode.
Windows / macOS / Linuxd then d
Undo all edits for the lineVi command mode.
Windows / macOS / LinuxU
Open the current command in the external editorVi command mode; Emacs uses Ctrl+X then Ctrl+E.
Windows / macOS / Linuxv
Start a Vi history searchVi command mode. The search starts after you accept the search text.
Windows / macOS / Linux/
Paste before the cursorVi command mode.
Windows / macOS / LinuxP
Paste after the cursorVi command mode.
Windows / macOS / Linuxp

Source

official Microsoft PSReadLine functions · Checked

Current PSReadLine functions and key handlers documented by Microsoft in August 2026. The active edit mode controls many defaults: Windows mode is common on Windows, while Emacs is the default on non-Windows. Check Get-PSReadLineKeyHandler for the exact local map.

Make a printable PowerShell sheet