I wish to install a program that is not available through the main channel in Nixos. How do I ensure that the proper dependencies will be installed, ideally in a way that is described in a configuration file that can be replicated as is with the rest of programs installed with nix?

1 Answer 1


You can simply nix-env -f /path/to/custom/nixpkgs -iA your-package.

Almost all dependencies in nixpkgs are pure, so the various versions on your system "don't affect each other". You can then nix-copy-closure that package to other machines, etc.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .