A muscle spasm, also known as a muscle cramp, is a painful but common occurrence. During a muscle spasm, the muscle contracts and will not release. A muscle spasm in the leg is also sometimes called a charley horse and may occur in the thigh or lower calf. Muscle spasms can be treated at home by stretching the muscle and massaging the affected area.
Overexertion
A person who participates in sports or exercise infrequently may overexert his muscles by attempting too much without being properly conditioned for the activity. During muscle overexertion, oxygen in the muscle decreases and the waste product lactic acid builds up. In some individuals, the spasm may not develop until four to six hours after the activity. Stretching and warming up before exercise can help reduce the chances of developing a muscle spasm.
Electrolyte Imbalance
The loss of potassium, magnesium and calcium in sweat may lead to muscle spasms. This can occur after heavy exercise or when a person has been exposed to extremely high temperatures. The symptoms of heat exhaustion may also be present along with muscle cramping if an electrolyte imbalance has developed as the result of exteme temperatures.
Another way to develop an electrolyte imbalance that leads to muscle spasms is through dehydration. Dehydration may stem from not drinking enough fluids or it may be the result of a loss of fluids through vomiting or frequent urination. Proper hydration and restoring the electrolyte balance are essential to fixing this type of cramp and preventing future occurrences.
Pregnancy
Pregnant women often experience muscle spasms in the lower leg, especially during the second and third trimesters. These cramps may occur at any time but are frequently reported at night, sometimes waking the woman from sleep. According to BabyCenter.com, the exact reason for leg cramps during pregnancy is unknown but may be due to the excess weight the woman is carrying or the pressure of the growing uterus on the blood vessels and nerves supplying the lower half of the body. Some women find that taking a magnesium supplement helps relieve these type of muscle spasms, notes BabyCenter.com.
Disease
Sometimes, muscle spasms may occur in the legs and other areas as a result of a systemic disease. Lou Gehrig's disease, Parkinson's disease, thyroid disease, cirrhosis of the liver and hardening of the arteries are all potential underlying disorders that a doctor may diagnose in a person with muscle cramps, according to the Your Orthopaedic Connection website.
Nerve Damage
If the nerves leading from the spinal cord to a muscle are damaged, the muscle may spontaneously develop cramps. This can occur from damage to a single nerve or to multiple nerves or nerve bundles, explains the University of Maryland Medical Center.


