This question already has an answer here:

In bash, we can use the up and down arrow keys to get the last or nth previous command in history.

Can we do this in zsh?

marked as duplicate by jasonwryan, thrig, chaos, Jakuje, Anthon Jan 12 '16 at 20:51

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.


According to man zshzle you should be able to

  • ctrl+n next history
  • ctrl+p previous history

man zshzle:

down-history (unbound) (^N) (unbound)
       Move to the next event in the history list

up-history (unbound) (^P) (unbound)
       Move to the previous event in the history list.


Also, not sure if you know already, but there is also oh-my-zsh. This customization of zsh does come with down/up as well as previously mentioned ctrl+n/ctrl+p for next/previous in history list, respectively

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