The most common injuries and causes of pain in the thigh are hamstring strains (back of the thigh) and quadriceps strains (front of the thigh). A thigh strain refers to an injury where the fibers in a quadriceps muscles are overstretched. Once the fibers are overstretched to a certain point, muscle tears occur.

Recommended rehab exercise: Use Deep Heat before exercise and Deep Freeze after exercise to rest & recover.
Gentle stretches and gentle leg strengthening exercises. Focusing on balance as well as full leg strengthening including the buttocks muscles.

Estimated time of recovery: Depending on the severity of the thigh strain generally take up to six weeks to 8 weeks.

How to prevent this injury from recurring: Adequate warm up and stretching prior to exercise or post-exercise. One can rub Deep Heat during the warmup phase. Gradual increase in your exercise intensity.
Regular leg massages. Full rehabilitation programs following any injury to the lower limb