DEV Community

Discussion on: Do you use BeautifulSoup or LXML to parse your HTML markup in Python?

Collapse
 
sm0ke profile image
Sm0ke

Hello,
I'm using BS to parse HTML themes, usually with 4/5 pages.
All related operations (page load, update properties on nodes, extract components) are executed in a few seconds, I never felt that perf is an issue with this small amount of input. Using a large amount of input data, maybe lxml can perform better.

On top of that, BS support lxml as plugin parser (along with html.parser ).