How to install LXML for Python 3 on 64-bit Windows

LXML is a “Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API.

Here is a list of the current installers from https://pypi.python.org/pypi/lxml/3.4.0:
lxml-installers

The two installersĀ for 64-bit Windows are for Python 2, but I needed a 64-bit Windows installer for Python 3.

The solution once again (see my Pygame post) was to grab the wheel file fromĀ http://www.lfd.uci.edu/~gohlke/pythonlibs/#lxml. Since I’d already installed pip and wheel, installing lxml from the wheel file was easy. At the Windows command prompt, enter:

pip install lxml-3.4.2-cp34-none-win_amd64.whl

And that’s all there is to it. Pretty printing with lxml is not as easy, but I’ll address that in a later post.

Related Training: Python

About Webucator

Webucator provides instructor-led training to students throughout the US and Canada. We have trained over 90,000 students from over 16,000 organizations on technologies such as Microsoft ASP.NET, Microsoft Office, Azure, Windows, Java, Adobe, Python, SQL, JavaScript, Angular and much more. Check out our complete course catalog.


One thought on “How to install LXML for Python 3 on 64-bit Windows”