============================== Helix 23.10 keyboard shortcuts ============================== First published at 1/17/2024 on https://defkey.com/helix-23-10-shortcuts Helix is a "modal text editor" with features such as Vim-like modal editing, multiple selections, and built-in language server support. Helix 23.10 has 313 shortcuts and we have listed all of them below. Normal mode: Movement --------------------- Normal mode is the default mode when you launch Helix. Return to it from other modes by typing Escape. NOTE: Unlike Vim, F, Shift+F, T and Shift+T are not confined to the current line. H Move left Left arrow Move left J Move down Down arrow Move down K Move up Up arrow Move up L Move right Right arrow Move right W Move next word start B Move previous word start E Move next word end Shift + W Move next word start Shift + B Move previous word start Shift + E Move next word end T Find until next char F Find next char Shift + T Find until previous char Shift + F Find previous char Shift + G Go to line number Alt + . Repeat last motion (f, t or m) Home Move to the start of the line End Move to the end of the line Ctrl + B Move page up Page Up Move page up Ctrl + F Move page down Page Down Move page down Ctrl + U Move half page up Ctrl + D Move half page down Ctrl + I Jump forward on the jumplist Ctrl + O Jump backward on the jumplist Ctrl + S Save the current selection to the jumplist Normal mode: Changes -------------------- R Replace with a character Shift + R Replace with yanked text ~ Switch case of the selected text ` Set the selected text to lower case Alt + ` Set the selected text to upper case I Insert before selection A Insert after selection (append) Shift + I Insert at the start of the line Shift + A Insert at the end of the line O Open new line below selection Shift + O Open new line above selection . Repeat last insert U Undo change Shift + U Redo change Alt + U Move backward in history Alt + Shift + U Move forward in history Y Yank selection P Paste after selection Shift + P Paste before selection " : Select a register to yank to or paste from > Indent selection < Unindent selection = Format selection (currently nonfunctional/disabled) (LSP) D Delete selection Alt + D Delete selection, without yanking C Change selection (delete and enter insert mode) Alt + C Change selection (delete and enter insert mode, without yanking) Ctrl + A Increment object (number) under cursor Ctrl + X Decrement object (number) under cursor Shift + Q Start/stop macro recording to the selected register (experimental) Q Play back a recorded macro from the selected register (experimental) Normal mode: Shell ------------------ | Pipe each selection through shell command, replacing with output Alt + | Pipe each selection into shell command, ignoring output ! Run shell command, inserting output before each selection Alt + ! Run shell command, appending output after each selection $ Pipe each selection into shell command, keep selections where command returned 0 Normal mode: Selection manipulation ----------------------------------- S Select all regex matches inside selections Shift + S Split selection into sub selections on regex matches Alt + S Split selection on newlines Alt + - Merge selections Alt + _ Merge consecutive selections & Align selection in columns _ Trim whitespace from the selection ; Collapse selection onto a single cursor Alt + ; Flip selection cursor and anchor Alt + : Ensures the selection is in forward direction , Keep only the primary selection Alt + , Remove the primary selection C Copy selection onto the next line (Add cursor below) Alt + C Copy selection onto the previous line (Add cursor above) ( Rotate main selection backward ) Rotate main selection forward Alt + ( Rotate selection contents backward Alt + ) Rotate selection contents forward % Select entire file X Select current line, if already selected, extend to next line Shift + X Extend selection to line bounds (line-wise selection) Alt + X Shrink selection to line bounds (line-wise selection) J Join lines inside selection Alt + Shift + J Join lines inside selection and select the inserted space Shift + K Keep selections matching the regex Alt + Shift + K Remove selections matching the regex Ctrl + C Comment/uncomment the selections Alt + O Expand selection to parent syntax node (TS) Alt + Up arrow Expand selection to parent syntax node (TS) Alt + I, Alt-down Shrink syntax tree object selection (TS) Alt + P Select previous sibling node in syntax tree (TS) Alt + Left arrow Select previous sibling node in syntax tree (TS) Alt + N Select next sibling node in syntax tree (TS) Alt + Right arrow Select next sibling node in syntax tree (TS) Normal mode: Search ------------------- Search commands all operate on the / register by default. To use a different register, use ". / Search for regex pattern ? Search for previous pattern N Select next search match Shift + N Select previous search match * Use current selection as the search pattern Normal mode: Minor modes ------------------------ These sub-modes are accessible from normal mode and typically switch back to normal mode after a command. V Enter select (extend) mode G Enter goto mode M Enter match mode : Enter command mode Z Enter view mode Shift + Z Enter sticky view mode Ctrl + W Enter window mode Space Enter space mode These modes (except command mode) can be configured by remapping keys. Normal mode: View mode ---------------------- Z View mode is accessed by typing z in normal mode View mode is intended for scrolling and manipulating the view without changing the selection. The "sticky" variant of this mode (accessed by typing Z in normal mode) is persistent and can be exited using the escape key. This is useful when you're simply looking over text and not actively editing it. Z Vertically center the line C Vertically center the line T Align the line to the top of the screen B Align the line to the bottom of the screen M Align the line to the middle of the screen (horizontally) J Scroll the view downwards Down arrow Scroll the view downwards K Scroll the view upwards Up arrow Scroll the view upwards Ctrl + F Move page down Page Down Move page down Ctrl + B Move page up Page Up Move page up Ctrl + D Move half page down Ctrl + U Move half page up Normal mode: Goto mode ---------------------- G Goto mode is accessed by typing g in normal mode. G Go to line number else start of file E Go to the end of the file F Go to files in the selection H Go to the start of the line L Go to the end of the line S Go to first non-whitespace character of the line T Go to the top of the screen C Go to the middle of the screen B Go to the bottom of the screen D Go to definition (LSP) Y Go to type definition (LSP) R Go to references (LSP) I Go to implementation (LSP) A Go to the last accessed/alternate file M Go to the last modified/alternate file N Go to next buffer P Go to previous buffer . Go to last modification in current file J Move down textual (instead of visual) line K Move up textual (instead of visual) line Normal mode: Match mode ----------------------- Accessed by typing m in normal mode. M Goto matching bracket (TS) S : Surround current selection with R : Replace surround character with D : Delete surround character A : Select around textobject I : Select inside textobject Normal mode: Window mode ------------------------ Ctrl + W Access Windows mode This layer is similar to Vim keybindings as Kakoune does not support windows. W Switch to next window Ctrl + W V Vertical right split Ctrl + V S Horizontal bottom split Ctrl + S Horizontal bottom split F Go to files in the selection in horizontal splits F Go to files in the selection in vertical splits H Move to left split Ctrl + H Move to left split Left arrow Move to left split J Move to split below Ctrl + J Move to split below Down arrow Move to split below K Move to split above Ctrl + K Move to split above Up arrow Move to split above L Move to right split Ctrl + I Move to right split Right arrow Move to right split Q Close current window O Only keep the current window, closing all the others H Swap window to the left J Swap window downwards K Swap window upwards L Swap window to the right Normal mode: Space mode ----------------------- Space Access space mode This layer is a kludge of mappings, mostly pickers. F Open file picker Shift + F Open file picker at current working directory B Open buffer picker J Open jumplist picker G Debug (experimental) K Show documentation for item under cursor in a popup (LSP) S Open document symbol picker (LSP) S Open workspace symbol picker (LSP) D Open document diagnostics picker (LSP) Shift + D Open workspace diagnostics picker (LSP) R Rename symbol (LSP) A Apply code action (LSP) H Select symbol references (LSP) ' Open last fuzzy picker W Enter window mode P Paste system clipboard after selections P Paste system clipboard before selections Y Yank selections to clipboard Shift + Y Yank main selection to clipboard Shift + R Replace selections by clipboard contents / Global search in workspace folder ? Open command palette Tip: Global search displays results in a fuzzy picker, use Space + ' to bring it back up after opening a file. Normal mode: Popup ------------------ Displays documentation for item under cursor. Ctrl + U Scroll up Ctrl + D Scroll down Normal: Unimpaired ------------------ These mappings are in the style of vim-unimpaired. ] then D Go to next diagnostic (LSP) [ then D Go to previous diagnostic (LSP) ] then Shift + D Go to last diagnostic in document (LSP) [ then Shift + D Go to first diagnostic in document (LSP) ] then F Go to next function (TS) [ then F Go to previous function (TS) ] then T Go to next type definition (TS) [ then T Go to previous type definition (TS) ] then A Go to next argument/parameter (TS) [ then A Go to previous argument/parameter (TS) ] then C Go to next comment (TS) [ then C Go to previous comment (TS) ] then Shift + T Go to next test (TS) [ then Shift + T Go to previous test (TS) ] then P Go to next paragraph [ then P Go to previous paragraph ] then G Go to next change [ then G Go to previous change ] then Shift + G Go to last change [ then Shift + G Go to first change ] then Space Add newline below [ then Space Add newline above Normal mode: Insert mode ------------------------ I Accessed insert mode Insert mode bindings are minimal by default. Helix is designed to be a modal editor, and this is reflected in the user experience and internal mechanics. Changes to the text are only saved for undos when escaping from insert mode to normal mode. Tip: It is recommended for new users to learn the modal editing paradigm to get the smoothest experience. Esc Switch to normal mode Ctrl + S Commit undo checkpoint Ctrl + X Autocomplete Ctrl + R Insert a register content Ctrl + W Delete previous word Alt + Backspace Delete previous word Alt + D Delete next word Alt + Del Delete next word Ctrl + U Delete to start of line Ctrl + K Delete to end of line Ctrl + H Delete previous char Backspace Delete previous char Shift + Backspace Delete previous char Ctrl + D Delete next char Del Delete next char Ctrl + J Insert new line Enter Insert new line These keys are not recommended, but are included for new users less familiar with modal editors. Up arrow Move to previous line Down arrow Move to next line Left arrow Backward a char Right arrow Forward a char Page Up Move one page up Page Down Move one page down Home Move to line start End Move to line end As you become more comfortable with modal editing, you may want to disable some insert mode bindings. You can do this by editing your config.toml file. Select / extend mode V Accessed Select / extend mode Select mode echoes Normal mode, but changes any movements to extend selections rather than replace them. Goto motions are also changed to extend, so that vgl, for example, extends the selection to the end of the line. Search is also affected. By default, n and N will remove the current selection and select the next instance of the search term. Toggling this mode before pressing n or N makes it possible to keep the current selection. Toggling it on and off during your iterative searching allows you to selectively add search terms to your selections. Picker: Keys to use within picker. Remapping currently not supported. Shift + Tab Previous entry Ctrl + P Previous entry Tab Next entry Down arrow Next entry Ctrl + N Next entry Page Up Page up Ctrl + U Page up Page Down Page down Ctrl + D Page down Home Go to first entry End Go to last entry Enter Open selected Alt + Enter Open selected in the background without closing the picker Ctrl + S Open horizontally Ctrl + V Open vertically CtrlTt Toggle preview Esc Close picker Ctrl + C Close picker Prompt ------ Keys to use within prompt, Remapping is not possible currently. Esc Close prompt Ctrl + C Close prompt Alt + B Backward a word Ctrl + Left arrow Backward a word Ctrl + B Backward a char Left arrow Backward a char Alt + F Forward a word Ctrl + Right arrow Forward a word Ctrl + F Forward a char Right arrow Forward a char Ctrl + E Move prompt end End Move prompt end Ctrl + A Move prompt start Home Move prompt start Ctrl + W Delete previous word Alt + Backspace Delete previous word Ctrl + Backspace Delete previous word Alt + D Delete next word Alt + Del Delete next word Ctrl + Del Delete next word Ctrl + U Delete to start of line Ctrl + K Delete to end of line Backspace Delete previous char Ctrl + H Delete previous char Shift + Backspace Delete previous char Del Delete next char Ctrl + D Delete next char Ctrl + D Insert a word under doc cursor, may be changed to Ctrl-r Ctrl-w later Ctrl + P Select previous history Up arrow Select previous history Ctrl + N Select next history Down arrow Select next history Ctrl + R Insert the content of the register selected by following input char Tab Select next completion item Shift + Tab Select previous completion item Enter Open selected Source: Helix Editor documentation Last modified on (UTC): Wednesday, January 17, 2024 Defkey © All rights reserved.