The recommended way to bootstrap setuptools on any system is to download ez_setup.py and run it using the target Python environment. Different operating systems have different recommended techniques to accomplish this basic routine, so below are some examples to get you started.

For best results, uninstall previous versions FIRST (see Uninstalling).

Using Windows 8 (which includes PowerShell 3) or earlier versions of Windows with PowerShell 3 installed, it’s possible to install with one simple Powershell command. Start up Powershell and paste this command:

The recommended way to install setuptools on Windows is to download ez_setup.py and run it. The script will download the appropriate distribution file and install it for you.

Once installation is complete, you will find an easy_install program in your Python Scripts subdirectory. For simple invocation and best results, add this directory to your PATH environment variable, if it is not already present. If you did a user-local install, the Scripts subdirectory is $env:APPDATA\Python\Scripts.

Download ez_setup.py and run it using the target Python version. The script will download the appropriate version and install it for you:

> wget https://bootstrap.pypa.io/ez_setup.py -O - | python

Note that you will may need to invoke the command with superuser privileges to install to the system Python:

> wget https://bootstrap.pypa.io/ez_setup.py -O - | sudo python

Alternatively, Setuptools may be installed to a user-local path:

> wget https://bootstrap.pypa.io/ez_setup.py -O - | python - --user

Note that on some older systems (noted on Debian 6 and CentOS 5 installations), wget may refuse to download ez_setup.py, complaining that the certificate common name *.c.ssl.fastly.net does not match the host name bootstrap.pypa.io. In addition, the ez_setup.py script may then encounter similar problems using wget internally to download setuptools-x.y.zip, complaining that the certificate common name of www.python.org does not match the host name pypi.python.org. Those are known issues, related to a bug in the older versions of wget (see Issue 59). If you happen to encounter them, install Setuptools as follows:

For more advanced installation options, such as installing to custom locations or prefixes, download and extract the source tarball from Setuptools on PyPI and run setup.py with any supported distutils and Setuptools options. For example:

On Windows, if Setuptools was installed using an .exe or .msi installer, simply use the uninstall feature of “Add/Remove Programs” in the Control Panel.

Otherwise, to uninstall Setuptools or Distribute, regardless of the Python version, delete all setuptools* and distribute* files and directories from your system’s site-packages directory (and any other sys.path directories) FIRST.

If you are upgrading or otherwise plan to re-install Setuptools or Distribute, nothing further needs to be done. If you want to completely remove Setuptools, you may also want to remove the ‘easy_install’ and ‘easy_install-x.x’ scripts and associated executables installed to the Python scripts directory.

Questions, comments, and bug reports should be directed to the distutils-sig mailing list. If you have written (or know of) any tutorials, documentation, plug-ins, or other resources for setuptools users, please let us know about them there, so this reference list can be updated. If you have working, tested patches to correct problems or add features, you may submit them to the setuptools bug tracker.

The original design for the .egg format and the pkg_resources API was co-created by Phillip Eby and Bob Ippolito. Bob also implemented the first version of pkg_resources, and supplied the OS X operating system version compatibility algorithm.

Ian Bicking implemented many early “creature comfort” features of easy_install, including support for downloading via Sourceforge and Subversion repositories. Ian’s comments on the Web-SIG about WSGI application deployment also inspired the concept of “entry points” in eggs, and he has given talks at PyCon and elsewhere to inform and educate the community about eggs and setuptools.

Jim Fulton contributed time and effort to build automated tests of various aspects of easy_install, and supplied the doctests for the command-line .exe wrappers on Windows.

Phillip J. Eby is the seminal author of setuptools, and first proposed the idea of an importable binary distribution format for Python application plug-ins.

Significant parts of the implementation of setuptools were funded by the Open Source Applications Foundation, to provide a plug-in infrastructure for the Chandler PIM application. In addition, many OSAF staffers (such as Mike “Code Bear” Taylor) contributed their time and stress as guinea pigs for the use of eggs and setuptools, even before eggs were “cool”. (Thanks, guys!)

Tarek Ziadé is the principal author of the Distribute fork, which re-invigorated the community on the project, encouraged renewed innovation, and addressed many defects.

Since the merge with Distribute, Jason R. Coombs is the maintainer of setuptools. The project is maintained in coordination with the Python Packaging Authority (PyPA) and the larger Python community.