Notepad++ split line after given number of words

Is there a way in notepad++, to split one line text, to text with given maximum number of words in one line? I can do this with characters but not with words


You can use this expression to add a new line after each 5 words:

  • look for: ((\w+\W+){5})
  • replace to: $1\n

make sure to check "regular expression"

You can test it here.