Is there a way to keep the buffer list open so I can select a buffer?

I.e., I do ls, then the buffer list shows up with the 'enter a command or press enter' prompt - I would like to press, for example, :5 but have the buffer list stay visible for this single command.

I'm pretty sure I've had this working before but I deleted my config X(

  • 1
    As in :ls<ENTER> then press colon : ... ? The "enter a command" is for example :b5
    – Moba
    Commented Jun 29, 2022 at 6:15
  • @Moba correct, I want to be able to still see the buffer list when typing b5 Commented Jun 29, 2022 at 16:37
  • @Moba is saying this should work by default. At the :help hit-enter prompt, you can immediately type :
    – D. Ben Knoble
    Commented Jun 29, 2022 at 19:39
  • @Ben I'm using Windows 10 and as soon as I hit : I lose the list of buffer built by :ls. Commented Jun 30, 2022 at 5:59
  • I'm currently using the wilder.nvim plugin. With the plugin the :b command build the list of existing buffer as a floating window on top of the command line. Commented Jun 30, 2022 at 6:17

2 Answers 2


If I understood correctly your question, this is a very popular request and not surprisingly, there is an equally popular mapping for it:

nnoremap <Leader>b :ls<CR>:b<Space>

(this assumes you already set mapleader, but you can change it if you want)

I have set <Leader> to \<space>, so when I press Space + b, the output of :ls is shown in addition to the command :b ready for you to type the number for the desired buffer and press Enter.


I propose you to use the wildmenu:

:set wildmenu

If set when using the :b (notice the trailing space) command you can use the Ctrld to ask for a list of possible completions which is somehow the full list of open buffers is you enter only one space as hit.

If you like to have the list of possible completion vertical I recommend you to install the wilder.nvm plugin.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.