match anything after a pattern in regex code example Example: Regular expression: Match everything after a particular word re.search(r'(?<=test :)[^.\s]*',text)