That is very likely to happen, nowadays.
Radiation emitted from the sun is steadily bypassing the Ozone layer, gradually making it more harmful against people exposed to the UV rays.
The Ozone layer's main function is to absorb most of the UV rays, and unfortunately in recent years, the Ozone layer has slowly been depleting in certain areas of the world. You may just be located in one of those areas...or your body is sensitive to the UV rays given off by the sun.
What you can do to ease your headache is get a clean towel, soak it with clean water, roll it up, and place it over your head while you lay down. It'll cool you down and gradually treat your headache.