Hydrostatic equilibrium is the state in which a fluid's internal pressure gradient balances the gravitational forces acting upon it, maintaining a stable configuration. This principle is crucial in understanding the structure of stars, planets, and other astronomical bodies, where it ensures that they do not collapse under their own gravity or disperse into space.