Nixos packages statistic

Is it possible to have a project for NixOS like pkgstats for Archlinux and gentoostats for Gentoo to statistic the package installed information, such as Browsers, Editors, Desktop Environments, …?


I guess you’d have to examine what metadata is available in nixpkgs packages.

Another source of data could possibly be

I don’t think the packages’ metadata / repology is very relevant, except for linking the metadata to the statistics on the website. As far as I understand the pkgstats software is simply a Systemd timer that sends the current state of the packages installed on the machine to the website’s server.

This idea sounds pretty cool, especially for NixOS, where people overriding packages from Nixpkgs, and people using Nixpkgs forks etc is a common setup, and this is interesting information! However, the statistics you’d get for this kind of information would have to be substantially different than what the traditional distributions collect, because people have a lot of garbage in their /nix/store.

Perhaps the right thing to do is to ask what the system.path attribute references to. Perhaps it’d even be possible to find out how often people update their systems this way.


If your concern is analysing what’s in use, it should look at all gc roots (perhaps then removing all but the most recent generation of each). This will catch most other use-cases too (devshells with direnv/nix-direnv/nix profile, installations via home-manager, and more).

I also feel like there’s a lot more scope for information leakage concerns here too, though, since much more of the actual configuration is in nix store (even if you only look at store paths, there are host and user names, mount points, etc).

Would need great care.


This idea sounds pretty cool

:smile: I just want a nixstat like pkgstat and gentoostat to statistic information and display them in a website to show how many Nix users use which browser, editor, DE, …

The still be many things need to be discussed. Such as Archlinux’s pkgstat collect enough data while there are very few people install gentoostat so it doesn’t collect enough data. How can we ensure nixstat will collect enough data?

1 Like

To start, if even just package download stats from the official nix-cache would be nice.