Installing MySQLdb for Python 3 in Windows

My favorite Python connector for MySQL or MariaDB is MySQLdb, the problem with this connector is that it is complicated to install on Windows!

I am creating this article for those who want to install MySQLdb for Python 3 for Windows. Especially me, since each time I am doing a Python project that needs to connect to MariaDB or MySQL I always look on how to install MySQLdb.

If you are interested why I prefer MySQLdb compared to other MySQL connectors you may want to read the comparison of MySQL-connector and MySQLdb from Charles Nagy.

Problems with installing MySQLdb on Windows

You can actually install MySQLdb using pip. See pypi documentation here.

pip install MySQL-python

Unfortunately, the pypi documentation is already out of date with the latest release was on Jan 3, 2014. Continue reading Installing MySQLdb for Python 3 in Windows