Electrical fire under hood occurred spontaneously. Just before my vehicle shut off the dash board read something about to conserve battery shut engine off. Pulled over got out of car and it burned . Insurance agent is investigating. Sherriff and fireman said it was electrical fire under hood. Had I not decided to pull over at rest stop when I did we would have been on freeway when it ignited.