The light and the heater are both connected to mains electricity through plugs in the wall. Both have metals inside that either get hot or shine brightly when electricity flows.