By chance do you have asthma and are using inhalers before your rides? I ask because I recently started to develop headaches while riding and I think it has to do with the inhalers by asthma doctor has me using so that I can breath while I ride.

I also wonder if your core body temp is not increasing while you ride triggering the headaches, just a guess.

I hope you figure this out soon.