Happened to me a couple times over the years. I always suspected (afterwards of course) I was on the edge of a virus perhaps but didn' realise it, then the physical exercise depleted me....causing me to crash (metaphorically speaking)
Edited to say...i always thought, cycling will soon highlight or bring forward any unwellness that was dwelling. There's also been a couple times I felt ok, went out for a ride, only to give up within a few miles. It just wasn' there, no point in pushing on, something's ailing me.