Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (
Help us improve Python packaging - Donate today!

Generate Nix expressions for Python packages.

Project Description


Generate nix expressions for Python packages.

Why another .nix generator for Python?

The original author of pip2nix started the project with the following motivation:

I needed something that can work not only with pypi but also with local paths, VCS links, and dependency links. I couldn’t get any of the other generators to work, so I started my own :-)


Be aware that pip2nix is not yet mature software. It is a tool to aid Python developers who use Nix to automate a good chunk of the work to maintain a Nix based development environments.

The recommended usage at the moment is inside of a nix-shell, since this avoids putting a specific version into the user’s environment:

$ git clone
$ cd pip2nix
$ nix-shell release.nix -A pip2nix.python36

Alternatively pip2nix can be installed into the user’s environment:

$ git clone
$ nix-env -f pip2nix/release.nix -iA pip2nix.python35


To generate python-packages.nix for a set of requirements:

$ pip2nix generate -r requirements.txt

pip2nix generate takes the same set of package specifications pip install does.


Problems and questions should go to GitHub issues.

Credits and History

Tomasz Kontusz started the project back in 2015, he’s ktosiek on Freenode, and @tkontusz on Twitter.

In 2016 Johannes Bornhold took over as maintainer, since he was actively using pip2nix and Tomas was not actively using it himself anymore. Find him via

Release History

This version
History Node


History Node


History Node


History Node


History Node


History Node


History Node


History Node


Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Hash SHA256 Hash Help Version File Type Upload Date
(24.3 kB) Copy SHA256 Hash SHA256
Source Jan 2, 2018

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting