remove all tags from text code example Example: remove all html tags and text from string python string = "<p>frwefb</p>" BeautifulSoup(string, "lxml").text