Mismatched versions between Home Manager and Nixpkgs

Hello.

After updating my system today I got the following warning:

evaluation warning: frostphoenix profile: You are using

                      Home Manager version 24.11 and
                      Nixpkgs version 25.05.

                    Using mismatched versions is likely to cause errors and unexpected
                    behavior. It is therefore highly recommended to use a release of Home
                    Manager that corresponds with your chosen release of Nixpkgs.

                    If you insist then you can disable this warning by adding

                      home.enableNixpkgsReleaseCheck = false;

                    to your configuration.

It appears every time I use nixos rebuild.
I am using nipkgs-unstable and home-manager is set to follow it, I never had this kind of issue before.

Here is my flake.nix file:

flake.nix
{
  description = "FrostPhoenix's nixos configuration";

  inputs = {
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
    nur.url = "github:nix-community/NUR";
  
    hypr-contrib.url = "github:hyprwm/contrib";
    hyprpicker.url = "github:hyprwm/hyprpicker";
  
    alejandra.url = "github:kamadorueda/alejandra/3.0.0";
  
    nix-gaming.url = "github:fufexan/nix-gaming";
  
    hyprland = {
      type = "git";
      url = "https://github.com/hyprwm/Hyprland";
      submodules = true;
    };
  
    home-manager = {
      url = "github:nix-community/home-manager";
      inputs.nixpkgs.follows = "nixpkgs";
    };
    
    spicetify-nix = {
      url = "github:gerg-l/spicetify-nix";
      inputs.nixpkgs.follows = "nixpkgs";
    };

    hyprmag.url = "github:SIMULATAN/hyprmag";

    nix-flatpak.url = "github:gmodena/nix-flatpak";

    zen-browser.url = "github:fufexan/zen-browser-flake";

    yazi-plugins = {
      url = "github:yazi-rs/plugins";
      flake = false;
    };
  };

  outputs = { nixpkgs, self, ...} @ inputs:
  let
    username = "frostphoenix";
    system = "x86_64-linux";
    pkgs = import nixpkgs {
      inherit system;
      config.allowUnfree = true;
    };
    lib = nixpkgs.lib;
  in
  {
    nixosConfigurations = {
      desktop = nixpkgs.lib.nixosSystem {
        inherit system;
        modules = [ ./hosts/desktop ];
        specialArgs = { host="desktop"; inherit self inputs username ; };
      };
      laptop = nixpkgs.lib.nixosSystem {
        inherit system;
        modules = [ ./hosts/laptop ];
        specialArgs = { host="laptop"; inherit self inputs username ; };
      };
       vm = nixpkgs.lib.nixosSystem {
        inherit system;
        modules = [ ./hosts/vm ];
        specialArgs = { host="vm"; inherit self inputs username ; };
      };
    };
  };
}

And if more detail is needed here is my config.

What could be the cause of this warning ?

1 Like

Nixpkgs recently changed the version number, but home manager needs some time to do the same. Because this happened so recently there probably won’t be any “errors and unexpected behavior” so you can just ignore the message for now (or if it’s really bothering you change the home.enableNixpkgsReleaseCheck value as suggested).

5 Likes

Thanks for the explanation. If it is just that I will let it like this and just wait for home manager to change their version number.

It’s been updated

1 Like

Funny, I have the opposite error. I’m using nixpkgs 24.11 which pulls in home-manager 25.05. This is weird

NixOS 24.11 doesn’t exist yet, so you’re not using it. You’re using 25.05-pre which corresponds to HM’s 25.05-pre. Such problems happen all the time around releases, since HM doesn’t coordinate with what nixpkgs does, though once NixOS 24.11 is released you can use the release-24.11 branch of HM.

1 Like

Has yours resolved now with 24.11 being officially released and Home Manager now having a 24.11 release available? I am still receiving the error and my flake.nix seems to be set correctly even after a nix flake update.

  inputs = {
    # Nixpkgs
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";

    # Home Manager
    home-manager.url = "github:nix-community/home-manager";
    home-manager.inputs.nixpkgs.follows = "nixpkgs";

Anyone have thoughts?

I think I might have finally figured it out … clearly I still have much to learn. I was previously running nixos-unstable for nixpkgs and have been trying to get switched over to running stable. I didn’t realize that I would need to update the home-manager URL with a specific release defined as well so I updated the inputs as follows and the warning went away:

  inputs = {
    # Nixpkgs
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";

    # Home Manager
    home-manager = {
      url = "github:nix-community/home-manager/release-24.11";
      inputs.nixpkgs.follows = "nixpkgs";  # Follows stable nixpkgs by default
    };

If someone knows that what I’ve done is still not correct, please correct me so this post doesn’t mislead the next person lol

Your fix is correct.

New to nix here, but wouldn’t you use release-24.11 as nixos branch instead?

Edit:
Answer is no, see reason here: FAQ - NixOS Wiki