The pseudo-incompressible approximation, which assumes small pressure perturbations from a one-dimensional reference state, has long been used to model large-scale dynamics in stellar and planetary atmospheres. However, existing implementations do not conserve energy when the reference state is time-dependent. We use a variational formulation to derive an energy-conserving pseudo-incompressible model in which the reference state evolves while remaining hydrostatic. We present an algorithm for solving these equations in the case of closed boundaries, for which the pseudo-incompressible velocity constraint is degenerate. We implement the model within the low-Mach-number code MAESTROeX, and validate it against a fully compressible model in several test cases, finding that our hybrid pseudo-incompressible–hydrostatic model generally shows better agreement with the compressible results than the existing MAESTROeX implementation.