That’s because fuel has far more energy density than batteries. Yet ICE cars still underestimate mileage.
On YouTube some guys did the experiment: driving and measuring mileage after fuel gauge dropped to empty and computer started to complain about fuel. They got about 40 miles.