# How does an expanding universe and a constant-density vacuum energy not violate energy conservation? [duplicate]

As per the title. I'm probably thinking too naively in a classical way, but intuitively it seems to me that:

1. the presence of vacuum energy at fixed density throughout all space and,
2. an expanding universe

would imply that more and more energy is constantly added to the universe.

I am assuming we have not given up on energy conservation quite yet, so where is the catch?

Energy conservation is equivalent to the Lagrangian's partial time derivative being $$0$$. In an FLRW spacetime, this fails. (In fact, total energy isn't always even well-defined in general relativity.)
While ordinary matter has a density proportional to $$a^{-3}$$ in a universe of scale factor $$a$$, dark energy is far from the only component of the universe that doesn't work like that, resulting in a volume-dependent contribution to total mass-energy. Radiation has an $$a^{-4}$$ density, so actually diminishes over time. This is why a radiation-dominated era preceded the matter-dominated era.