# IPython shortcuts

Available shortcut in IPython terminal.

Warning

This list is automatically generated, and may not hold all the available shortcut. In particular, it may depends on the version of `prompt_toolkit` installed during the generation of this page.

## Single Filtered shortcuts

Shortcut | Filter | Description
--- | --- | ---
`<PageDown>` | (Not: HasSelection) | Move `forward` through the history list, fetching the next command
`<PageUp>` | (Not: HasSelection) | Move `back` through the history list, fetching the previous command
`<Bracketed-Paste>` | Always | Pasting from clipboard
`<C-C>` | Always | Abort when Control-C has been pressed
`<C-Down>` | Always | Move `forward` through the history list, fetching the next command
`<C-L>` | Always | Clear the screen and redraw everything at the top of the screen
`<C-Up>` | Always | Move `back` through the history list, fetching the previous command
`<C-Z>` | Always | By default, control-Z should literally insert Ctrl-Z
`<Cursor-Position-Response>` | Always | Handle incoming Cursor-Position-Request response
`<End>` | Always | Move to the end of the line
`<Home>` | Always | Move to the start of the current line
`<Left>` | Always | Move back a character
`<Right>` | Always | Move forward a character
`<Vt100-Mouse-Event>` | Always | Handling of incoming mouse event
`<Windows-Mouse-Event>` | Always | Handling of mouse events for Windows
`<Any>` | Condition | Handle quoted insert
`<C-D>` | Condition | Exit
`<C-E>` | Condition | Accept suggestion
`<C-F>` | Condition | Accept suggestion
`<Right>` | Condition | Accept suggestion
`<C-A>` | EmacsMode | Move to the start of the current line
`<C-B>` | EmacsMode | Move back a character
`<C-E>` | EmacsMode | Move to the end of the line
`<C-F>` | EmacsMode | Move forward a character
`<C-Left>` | EmacsMode | Move back to the start of the current or previous word
`<C-N>` | EmacsMode | Next line
`<C-O>` | EmacsMode | Accept the current line for execution and fetch the next line relative to the current line from the history for editing
`<C-P>` | EmacsMode | Previous line
`<C-Right>` | EmacsMode | Move forward to the end of the next word
`<C-Space>` | EmacsMode | Start of the selection (if the current buffer is not empty)
`<C-SquareClose> <Any>` | EmacsMode | When Ctl-] + a character is pressed
`<C-X> (` | EmacsMode | Begin saving the characters typed into the current keyboard macro
`<C-X> )` | EmacsMode | Stop saving the characters typed into the current keyboard macro and save the definition
`<C-X> <C-X>` | EmacsMode | Move cursor back and forth between the start and end of the current line
`<C-X> e` | EmacsMode | Re-execute the last keyboard macro defined, by making the characters in the macro appear as if typed at the keyboard
`<Escape>` | EmacsMode | By default, ignore escape key
`<Escape> <C-SquareClose> <Any>` | EmacsMode | Like Ctl-], but backwards
`<Escape> <Left>` | EmacsMode | Cursor to start of previous word
`<Escape> <Right>` | EmacsMode | Cursor to start of next word
`<Escape> a` | EmacsMode | Previous sentence
`<Escape> b` | EmacsMode | Move back to the start of the current or previous word
`<Escape> e` | EmacsMode | Move to end of sentence
`<Escape> f` | EmacsMode | Move forward to the end of the next word
`!` | Never | ‘!’ opens the system prompt
`<C-B>` | Never | Scroll window up
`<C-D>` | Never | Same as ControlF, but only scroll half a page
`<C-E>` | Never | scroll_offset += 1
`<C-F>` | Never | Scroll window down
`<C-J>` | Never | Run system command
`<C-U>` | Never | Same as ControlB, but only scroll half a page
`<C-V>` | Never | Scroll page down
`<C-X> <C-E>` | Never | Invoke an editor on the current command line, and accept the result
`<C-Y>` | Never | scroll_offset -= 1
`<C-Z>` | Never | Suspend process to background
`<Escape> !` | Never | M-‘!’ opens the system prompt
`<Escape> v` | Never | Scroll page up
`<PageDown>` | Never | Scroll page down
`<PageUp>` | Never | Scroll page up
`v` | Never | Invoke an editor on the current command line, and accept the result
`<Escape>` | ViMode | Escape goes to vi navigation mode

## Multi Filtered shortcuts

Shortcut | Filter | Description
--- | --- | ---
`<C-J>` | (And: (Not: Condition), Condition) | Enter, accept input
`<C-D>` | (And: Condition, (Or: ViInsertMode, EmacsInsertMode)) | Delete character before the cursor
`<C-J>` | (And: Condition, (Or: ViInsertMode, EmacsInsertMode)) | Newline (in case of multiline input
`<Escape> -` | (And: EmacsMode, (Not: HasArg)) |
`<C-G>` | (And: EmacsMode, (Not: HasSelection)) | Control + G: Cancel completion menu and validation state
`<C-Q>` | (And: EmacsMode, (Not: HasSelection)) | Add the next character typed to the line verbatim
`<Escape> <` | (And: EmacsMode, (Not: HasSelection)) | Move to the first line in the history
`<Escape> >` | (And: EmacsMode, (Not: HasSelection)) | Move to the end of the input history, i
`-` | (And: EmacsMode, Condition) | When ‘-‘ is typed again, after exactly ‘-‘ has been given as an argument, ignore this
`<C-Delete>` | (And: EmacsMode, EmacsInsertMode) | Kill from point to the end of the current word, or if between words, to the end of the next word
`<C-Underscore>` | (And: EmacsMode, EmacsInsertMode) | Incremental undo
`<C-X> <C-U>` | (And: EmacsMode, EmacsInsertMode) | Incremental undo
`<C-X> r y` | (And: EmacsMode, EmacsInsertMode) | Paste before cursor
`<C-Y>` | (And: EmacsMode, EmacsInsertMode) | Paste before cursor
`<Escape> #` | (And: EmacsMode, EmacsInsertMode) | Without numeric argument, comment all lines
`<Escape> *` | (And: EmacsMode, EmacsInsertMode) | `meta-*`: Insert all possible completions of the preceding text
`<Escape> .` | (And: EmacsMode, EmacsInsertMode) | Like `yank_nth_arg`, but if no argument has been given, yank the last word of each line
`<Escape> /` | (And: EmacsMode, EmacsInsertMode) | M-/: Complete
`<Escape> <Backspace>` | (And: EmacsMode, EmacsInsertMode) | Kills the word before point, using “not a letter nor a digit” as a word boundary
`<Escape> <C-H>` | (And: EmacsMode, EmacsInsertMode) | Kills the word before point, using “not a letter nor a digit” as a word boundary
`<Escape> <C-Y>` | (And: EmacsMode, EmacsInsertMode) | Insert the first argument of the previous command
`<Escape> \` | (And: EmacsMode, EmacsInsertMode) | Delete all spaces and tabs around point
`<Escape> _` | (And: EmacsMode, EmacsInsertMode) | Like `yank_nth_arg`, but if no argument has been given, yank the last word of each line
`<Escape> c` | (And: EmacsMode, EmacsInsertMode) | Capitalize the current (or following) word
`<Escape> d` | (And: EmacsMode, EmacsInsertMode) | Kill from point to the end of the current word, or if between words, to the end of the next word
`<Escape> l` | (And: EmacsMode, EmacsInsertMode) | Lowercase the current (or following) word
`<Escape> t` | (And: EmacsMode, EmacsInsertMode) | Swap the last two words before the cursor
`<Escape> u` | (And: EmacsMode, EmacsInsertMode) | Uppercase the current (or following) word
`<Escape> y` | (And: EmacsMode, EmacsInsertMode) | Rotate the kill ring, and yank the new top
`<Escape> <C-J>` | (And: EmacsMode, EmacsInsertMode, Condition) | Accept the line regardless of where the cursor is
`<C-C>` | (And: EmacsMode, HasFocus) | Abort an incremental search and restore the original line
`<C-G>` | (And: EmacsMode, HasFocus) | Abort an incremental search and restore the original line
`<C-J>` | (And: EmacsMode, HasFocus) | When enter pressed in isearch, quit isearch mode
`<Escape>` | (And: EmacsMode, HasFocus) | When enter pressed in isearch, quit isearch mode
`<C-C> <` | (And: EmacsMode, HasSelection) | Unindent selected text
`<C-C> >` | (And: EmacsMode, HasSelection) | Indent selected text
`<C-G>` | (And: EmacsMode, HasSelection) | Cancel selection
`<C-W>` | (And: EmacsMode, HasSelection) | Cut selected text
`<C-X> r k` | (And: EmacsMode, HasSelection) | Cut selected text
`<Escape> w` | (And: EmacsMode, HasSelection) | Copy selected text
`<C-R>` | (And: ViMode, (Not: HasFocus)) | Vi-style backward search
`<C-S>` | (And: ViMode, (Not: HasFocus)) | Vi-style forward search
`<C-K>` | (And: ViMode, (Or: ViInsertMode, ViReplaceMode)) | Go into digraph mode
`z +` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Scrolls the window to makes the current line the first line in the visible region
`z -` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Scrolls the window to makes the current line the last line in the visible region
`z <C-J>` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Scrolls the window to makes the current line the first line in the visible region
`z b` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Scrolls the window to makes the current line the last line in the visible region
`z t` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Scrolls the window to makes the current line the first line in the visible region
`z z` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode)) | Center Window vertically around cursor
`/` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode), (Not: Condition)) | Vi-style forward search
`?` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode), (Not: Condition)) | Vi-style backward search
`/` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode), Condition) | Vi-style backward search
`?` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode), Condition) | Vi-style forward search
`0` | (And: ViMode, (Or: ViNavigationMode, ViSelectionMode, ViWaitingForTextObjectMode), HasArg) | Zero when an argument was already give
`I` | (And: ViMode, Condition, (Not: IsReadOnly)) | Insert in block selection mode
`G` | (And: ViMode, HasArg) | If an argument is given, move to this line in the history
`<C-C>` | (And: ViMode, HasFocus) | Cancel search
`<C-J>` | (And: ViMode, HasFocus) | Apply the search
`<Escape>` | (And: ViMode, HasFocus) | Apply the search
`<Backspace>` | (And: ViMode, HasFocus, Condition) | Cancel search
`<C-H>` | (And: ViMode, HasFocus, Condition) | Cancel search
`<Any>` | (And: ViMode, ViDigraphMode, Condition) | Insert digraph
`<C-E>` | (And: ViMode, ViInsertMode) | Cancel completion
`<C-P>` | (And: ViMode, ViInsertMode) | Control-P: To previous completion
`<C-V>` | (And: ViMode, ViInsertMode) | Add the next character typed to the line verbatim
`<C-X> <C-F>` | (And: ViMode, ViInsertMode) | Complete file names
`<C-X> <C-L>` | (And: ViMode, ViInsertMode) | Pressing the ControlX - ControlL sequence in Vi mode does line completion based on the other lines in the document and the history
`<C-Y>` | (And: ViMode, ViInsertMode) | Accept current completion
`<Any>` | (And: ViMode, ViInsertMultipleMode) | Insert data at multiple cursor positions at once
`<Backspace>` | (And: ViMode, ViInsertMultipleMode) | Backspace, using multiple cursors
`<Delete>` | (And: ViMode, ViInsertMultipleMode) | Delete, using multiple cursors
`" <Any> P` | (And: ViMode, ViNavigationMode) | Paste (before) from named register
`" <Any> p` | (And: ViMode, ViNavigationMode) | Paste from named register
`#` | (And: ViMode, ViNavigationMode) | Go to previous occurence of this word
`*` | (And: ViMode, ViNavigationMode) | Go to next occurence of this word
`+` | (And: ViMode, ViNavigationMode) | Move to first non whitespace of next line
`-` | (And: ViMode, ViNavigationMode) | Move to first non whitespace of previous line
`< <` | (And: ViMode, ViNavigationMode) | Unindent lines
`<Backspace>` | (And: ViMode, ViNavigationMode) | In navigation-mode, move cursor
`<C-H>` | (And: ViMode, ViNavigationMode) | In navigation-mode, move cursor
`<C-J>` | (And: ViMode, ViNavigationMode) | In navigation mode, pressing enter will always return the input
`<C-N>` | (And: ViMode, ViNavigationMode) | Arrow down and Control-N in navigation mode
`<C-P>` | (And: ViMode, ViNavigationMode) | Arrow up and ControlP in navigation mode go up
`<C-V>` | (And: ViMode, ViNavigationMode) | Enter block selection mode
`<Down>` | (And: ViMode, ViNavigationMode) | Arrow down and Control-N in navigation mode
`<Insert>` | (And: ViMode, ViNavigationMode) | Presing the Insert key
`<Up>` | (And: ViMode, ViNavigationMode) | Arrow up and ControlP in navigation mode go up
`> >` | (And: ViMode, ViNavigationMode) | Indent lines
`N` | (And: ViMode, ViNavigationMode) | Search previous in navigation mode
`P` | (And: ViMode, ViNavigationMode) | Paste before
`R` | (And: ViMode, ViNavigationMode) | Go to ‘replace’-mode
`V` | (And: ViMode, ViNavigationMode) | Start lines selection
`Y` | (And: ViMode, ViNavigationMode) | Yank the whole line
`d d` | (And: ViMode, ViNavigationMode) | Delete line
`j` | (And: ViMode, ViNavigationMode) | Go down, but if we enter a new history entry, go to the start of the line
`k` | (And: ViMode, ViNavigationMode) | Go up, but if we enter a new history entry, move to the start of the line
`n` | (And: ViMode, ViNavigationMode) | Search next in navigation mode
`p` | (And: ViMode, ViNavigationMode) | Paste after
`r <Any>` | (And: ViMode, ViNavigationMode) | Replace single character under cursor
`v` | (And: ViMode, ViNavigationMode) | Enter character selection mode
`x` | (And: ViMode, ViNavigationMode) | Delete character
`y y` | (And: ViMode, ViNavigationMode) | Yank the whole line
`~` | (And: ViMode, ViNavigationMode) | Reverse case of current character and move cursor forward
`C` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | # Change to end of line
`J` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Join lines
`O` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Open line above and enter insertion mode
`S` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Change current line
`c c` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Change current line
`g J` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Join lines without space
`g U U` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Uppercase current line
`g u u` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Lowercase current line
`g ~ ~` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Swap case of the current line
`o` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Open line below and enter insertion mode
`s` | (And: ViMode, ViNavigationMode, (Not: IsReadOnly)) | Substitute with new text (Delete character(s) and go to insert mode
`<Any>` | (And: ViMode, ViReplaceMode) | Insert data at cursor position
`<C-V>` | (And: ViMode, ViSelectionMode) | Exit block selection mode, or go from non block selection mode to block selection mode
`V` | (And: ViMode, ViSelectionMode) | Exit line selection mode, or go from non line selection mode to line selection mode
`a W` | (And: ViMode, ViSelectionMode) | Switch from visual linewise mode to visual characterwise mode
`a w` | (And: ViMode, ViSelectionMode) | Switch from visual linewise mode to visual characterwise mode
`j` | (And: ViMode, ViSelectionMode) | Arrow down in selection mode
`k` | (And: ViMode, ViSelectionMode) | Arrow up in selection mode
`v` | (And: ViMode, ViSelectionMode) | Exit character selection mode, or go from non-character-selection mode to character selection mode
`x` | (And: ViMode, ViSelectionMode) | Cut selection
`J` | (And: ViMode, ViSelectionMode, (Not: IsReadOnly)) | Join selected lines
`g J` | (And: ViMode, ViSelectionMode, (Not: IsReadOnly)) | Join selected lines without space
`<Any>` | (Or: ViInsertMode, EmacsInsertMode) | Insert yourself
`<BackTab>` | (Or: ViInsertMode, EmacsInsertMode) | Move backward through the list of possible completions
`<Backspace>` | (Or: ViInsertMode, EmacsInsertMode) | Delete the character behind the cursor
`<C-H>` | (Or: ViInsertMode, EmacsInsertMode) | Delete the character behind the cursor
`<C-I>` | (Or: ViInsertMode, EmacsInsertMode) | Generate completions, or go to the next completion
`<C-K>` | (Or: ViInsertMode, EmacsInsertMode) | Kill the text from the cursor to the end of the line
`<C-T>` | (Or: ViInsertMode, EmacsInsertMode) | Emulate Emacs transpose-char behavior: at the beginning of the buffer, do nothing
`<C-U>` | (Or: ViInsertMode, EmacsInsertMode) | Kill backward from the cursor to the beginning of the current line
`<C-W>` | (Or: ViInsertMode, EmacsInsertMode) | Kill the word behind point, using whitespace as a word boundary
`<Delete>` | (Or: ViInsertMode, EmacsInsertMode) | Delete character before the cursor
`<ShiftDelete>` | (Or: ViInsertMode, EmacsInsertMode) | Delete character before the cursor