What is system.configurationRevision for?

The nix options page just says “The Git revision of the top-level flake from which this configuration was built.” I don’t see much else when looking it up. An automatically generated nix-darwin configuration includes it:

# Set Git commit hash for darwin-version.
system.configurationRevision = self.rev or self.dirtyRev or null;

It lets you track which version of your flake that your system was built from, if you track it in a source control system.

For example, on my system nixos-version —json gives me this output:

{

“configurationRevision”:“2c4462630351e4298e7a9b8195420e4fce0f9468-dirty”,

“nixosVersion”:“25.11.20260316.48652e9”,

“nixpkgsRevision”:“48652e9d5aea46e555b3df87354280d4f29cd3a3”

}

This lets me track which version of my configuration was used when building the system I am using.

The nixosVersion and nixpkgsRevison is not enough to identify the system uniquely as the configuration is applied on top of those, so the configurationRevision identifies what configuration was used.

3 Likes