Muscle cramps can be a very painful and frustrating experience, particularly when they seem to come out of the blue. There are several things that can cause muscle cramps, and you should always feel free to discuss this or any other health concern with your primary care provider. He or she can do a more detailed history and physical exam to determine if these cramps are something incidental or part of a change in your overall health. In addition, it may be helpful to check a few basic laboratory values to make sure that your electrolytes are all at the appropriate level.
As you indicate, dehydration can sometimes contribute to muscle cramps. However, the reason for this is not so much because of dehydration itself but rather because of electrolyte imbalances that often accompany decreased fluid intake or increased fluid losses. If you have been drinking only water, it is possible that your potassium or magnesium levels may be part of the problem. It may be helpful for you to augment your regular water intake (always a good idea!) with sports drinks designed to replenish your electrolytes. However, since many of these drinks also contain a high amount of sugar, you want to be careful that you don't add
too many excess calories by switching all of your fluid intake to sports drinks.
Again, please discuss with your doctor
for more information.