This is something I've always wondered too. I have been plagued by migraines and daily headaches since I was 17 getting worse as I got older. The ONLY time I've had permanent relief is through pregnancy. In both my pregnancies I had one bad migraine in the first weeks of pregnancy followed by months of blissful relief only for them to return shortly after I gave birth.
I have talked to my doctor about it, she is of the opinion that my migraines are caused by the fluctuating hormone levels during my menstrual cycle. I have a bad headache all through my period every single month. My last period I was in bed in agony for 5 days :( I also often get a bad migraine during my ovulation. In between these episodes I am never truly free of pain. I always have a headache of some degree or another.
Birth control pills make me worse so they are not an option. I did some research and I think its something to do with the higher levels or estrogen in your body during pregnancy, which would make sense as estrogen levels fluctuate a lot during a womans menstrual cycle and not so much in pregnancy (especially in later stages).
I have even asked my doctor if I could have a hysterectomy as I am sooooo tired of it and at 39 not likely to have more children. She refused saying in the UK they would not perform the operation just for migraine as otherwise I'm perfectly healthy.
Also most of the women in my family suffer with headaches and all over 50 have said there headaches finally stopped after menopause so there is no doubt in my mind there is a link there :)
Hope this helps :)