I had a similar problem. It was a weak battery with me.
I was in a gas line and the speedometer was fluctuating wildly, and the car just died. I needed a jump start.
After driving back home, it started good. Then, after a few hours of not doing anything, the car didn't start again. Replaced the battery, and it worked fine.
By any chance, do your headlights "flicker"? Like it dims and brightens a few times per second?