There are two installers for Nix on macOS: the official one and the Determinate Systems installer. Use the Determinate Systems installer. It's the same Nix, but with two practical differences that matter on a Mac.
First, the Determinate Systems installer survives macOS major upgrades. The official installer relies on a synthetic /nix mount that macOS sometimes obliterates during version bumps; you wake up to a broken Nix install. Determinate's installer puts /nix on its own APFS volume that macOS won't touch.
Second, it has a clean uninstaller. Run /nix/nix-installer uninstall and your Mac is back to its pre-Nix state. The official installer's removal process is multi-step and easy to botch.
After install, restart your terminal (or source the new shell init), and verify with nix --version. You'll get Nix 2.x with flakes and the new nix command both enabled by default — that's the modern setup. If you ever see docs that say 'enable flakes by editing nix.conf', you're reading old docs; Determinate's installer flips both flags for you.