Eating enough of the right foods. Sleeping enough. Drinking plenty of water. Stretching after weight training. I also add the following in to my routine to help me recover:
1) infrared sauna 2-3 times per week
2) deep tissue work once per week
3) very little sugar and dairy only once per week
4) intermittent fasting. I fast for 16 hours every day.
5) magnesium and potassium supplementation. This can be done through actual supplements, float tank therapy, using sea salt in food, epsom salt baths, or a combination thereof