Most likely the starter or starter solenoid..
Random or intermittent no turn over..
That is the typical symptoms I have run into on any of the Ford Modular engine series (5.4/6.8) once they get some age..
Starter solenoid is mounted to the top or side of the starter and is not replaceable and is subjected to a lot of dampness. Bad for high power connections and the internal parts of the solenoid.
Replace the starter, NOW, it is warning you, the next time may and most likely will be in a place worse than your driveway..
Be forewarned if you DIY replace, the top starter bolt if you are not careful WILL round off, I guarantee this! Steel bolts going into aluminum engine block = STUCK BOLTS!
My first attempt after reading these warnings resulted in rounding a bolt head.. I gave up and had my truck towed to a garage and they used 6 ft of extensions out the front of the truck to get 100% straight lined up to get that top bolt.
Second truck with the modular engine I had it towed straight to a garage and didn't monkey with it..