Regular Hexpressions You can't parse [X]HTML with regex. Regex is not a tool that can be used to correctly parse HTML. Have you tried using regex to defuse a bomb instead?