How do I find text with yanked text on vim?

The most recently yanked text will be stored in the 0 and " registers (if no register was explicitly specified e.g. by "xy).

Then you can paste the text of any that register in the last line (either in search mode / or in last line command mode : ) with Ctrl-RX, where X is the register you want to paste.

For example:

/Ctrl-R0

Will paste the contents of the register 0 in the forward search command pattern.


  1. yank the text
  2. press q/pEnter

q/: open the search history

pEnter: paste the yanked text on the command line and search