FISH_VI_KEY_BINDINGS(1)

🌸 FISH_VI_KEY_BINDINGS(1) 🌸

okay bestie, so this is a page from the fish-shell manual, and it's literally the glow-up that turns your shell into vim. buckle up πŸ’–


✨ NAME ✨

fish_vi_key_bindings β€” set vi key bindings for fish


✨ SYNOPSIS ✨

fish_vi_key_bindings
fish_vi_key_bindings [--no-erase] [INIT_MODE]

✨ DESCRIPTION ✨

okay so fish_vi_key_bindings sets the vi key bindings for the fish shell. that's it, that's the whole vibe. πŸ¦‹

if you hand it a valid INIT_MODE β€” and the valid ones are insert, default, and visual β€” then that mode becomes the default mode. if you don't give it an INIT_MODE at all? no stress, the mode just defaults to insert mode. slay. πŸ’…

the following parameters are available:

  • --no-erase β€” does not clear previous set bindings. like, it leaves your old bindings exactly where they are instead of wiping them. πŸŽ€
heads up, there's more info waiting for you on how to use vi mode over at the vi mode section (#vi-mode). iykyk πŸ”₯

✨ DIFFERENCES FROM VIM ✨

fish's vi mode is lowkey designed to feel familiar to vim users, but there are some differences, and we're gonna be honest about them:

🫢 Word character handling

in vim, underscore (_) is treated as a keyword character by default, so word motions like w, b, and e treat foo_bar as a single word. one word. one unit. no cap.

in fish, underscore is treated as punctuation, so word motions stop at underscores. for example, pressing w on foo_bar in fish stops at the _, while in vim it would jump past the entire identifier. 😭 it's giving tiny betrayal, but now you know, so we move. ✨


✨ EXAMPLES ✨

to start using vi key bindings, literally just run:

fish_vi_key_bindings

or, if you want it permanent, set set -g fish_key_bindings fish_vi_key_bindings in config.fish (more on that in the configuration section, #configuration). 🧚 set it and forget it, iconic behavior honestly. πŸ‘‘


fish-shell developers


and that's the whole page, bestie! 🫢 this was from the fish-shell manual, version 4.9, dated Sep 08, 2026 β€” go forth and w your way through the shell. πŸ“πŸŒˆπŸ’œ
πŸ“¦ where this page comes from
  • arch rolling: fish 4.9.3-1 Β· GPL-2.0-only AND BSD-3-Clause AND ISC AND MIT AND PSF-2.0
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms