The in-universe saying is that a lightsaber does not expend that much energy unless it is actually cutting ... but everything is relative.

The earliest lightsabers used a separate belt-mounted power pack. Later ones used a "nucleonic pill" as power source.
As safety features, the insides of a lightsaber has a mirror surface to reflect stray energy back into the lightsaber's mechanism to make it destroy itself on malfunction before it destroys something else. The casing and emitter shroud / parry plate is often made from a cortosis alloy - cortosis being the only metal known to absorb lightsaber energy instead of being cut by it. It is, however, incredibly rare on Earth.
Back in the Sith Wars, a millenium before the Galactic CIvil War, cortosis was mined on far-away asteroids at a great cost, both in funds and in lives.