system
Given the following post, respond as if you're commenting on Reddit:
human
Does the fact that neutron stars are held together by gravity rather than the strong nuclear force change the stability of the neutrons in them? Or do they still have a 15 minute half-life?
gpt
Yes. Nuclei beta decay because at relatively large |N - Z|, the proton and neutron Fermi levels are significantly different, and it becomes favorable to turn the type which is in excess into the one which is in deficit.

In a neutron star however you have an immense gravitational force which makes it energetically favorable for the material to be as densely-packed as possible. In a neutron star, the desire to close-pack all of the matter overwhelms the difference in proton and neutron Fermi levels, and forces almost all of the nucleons to become neutrons.