Often it's due to poor iron levels so you should make sure you get a blood test which indicates your ferretin levels (iron storage). Low iron can affect hair, skin and/or nails. It seems to have only affected my hair, but a friend of mine still has good hair but her nails are like paper. I dont know why the body picks and chooses, maybe it's due to us all being individuals. If it is due to low ferretin levels, most doctors will tell you that for proper hair growth process your ferretin level should be 70 or over or as close to 70 as possible.
My iron was low for about 6yrs, but i didnt know it was an issue at the time and as i wasted 6yrs blaming everything from shampoo to stress the low iron ended up affecting my thyroid, which isnt bad enough for medicating, but is out enough to cause side effects.
If you get a thyroid test make certain your doctor doesnt only do the TSH test as that is useless on its own, you need the T3 and T4 along with it. Some doctors will say your thyroid is ok so long as your thyroid test doesnt show that you are at the point of needing medication and these same doctors dont believe that if it's only borderline out that you can suffer side effects like hair loss.
In addition to my iron and thyroid levels being out, my Vitamin D and iodine were very low. Get your doctor to do a thorough indepth blood test.
Hair loss can be hereditary, but that if its uniform hair loss all over your scalp and you do get regrowth but it falls out, then it is likely due to being defficient in something or a medical condition. Dont wait 6yrs like i did to pinpoint what it is. I've been doing something about mine for almost a year now, but as i waited too long and hit rockbottom with my iron it is now taking for ever to get my iron corrected.