How to Treat Sore Muscles
To treat sore muscles at home, try lightly stretching the muscles 2-3 times a day. If the soreness is a result of a recent injury, apply an ice pack to the muscles for 10-20 minutes every few hours. If you're dealing with chronic muscle soreness, apply heat to the muscles for 20 minutes every few hours by taking a warm bath or using a heating pad. Remember to drink plenty of water throughout the day, which will help prevent muscle cramping. If the soreness persists, you may want to take an over-the-counter pain reliever like ibuprofen.
Rest and take it easy. Most muscle soreness happens from either lifting too much weight, doing some activity too often, moving awkwardly or experiencing physical trauma (motor vehicle accidents, sports injuries). As such, the first step with any pulled or strained muscle that becomes sore is to rest it and stop doing the activity that caused the injury. You may need to take a few days off work or away from your sports team (depending on severity), but sore muscles recover quicker if they are given the appropriate time to rest. If your muscle soreness takes longer than a few weeks to fade away, then either a significant proportion of muscle fiber is torn (considered a Grade 2 or Grade 3 muscle strain) or related joints and ligaments are also injured. Dull, achy pain usually indicates a mild-to-moderate muscle strain, whereas sharp and/or shooting pain with movement is often caused by joint and/or ligament sprains. If your sore muscle is exercise related, you may be working out too aggressively or with bad form — consult with a personal trainer. Apply cold therapy for acute muscle soreness. If your muscle soreness is acute (developed recently), then inflammation is likely an issue and should be addressed with cold therapy. Apply cold therapy (crushed ice, a frozen gel pack or a bag of peas from the freezer) to the sorest part of the involved muscle in order to reduce inflammation and pain. Cold therapy causes the local blood vessels to constrict, which prevents excessive swelling, and it numbs small nerve fibers. Apply cold therapy for 10 to 20 minutes every few hours (the larger or deeper the affected muscle, the longer the time), then reduce the frequency as your muscle soreness subsides. Compressing the cold therapy against your sore muscle with a stretchy bandage or elastic wrap will also help combat swelling, but be careful not to completely cut off circulation. Wrap any type of cold therapy in a thin towel in order to prevent irritation or frostbite on your skin. Apply moist heat for chronic muscle soreness. If your muscle soreness has become chronic (lasting for more than a month) and feels more stiff instead of acutely inflamed, then apply moist heat instead of cold therapy to get relief. Microwavable herbal bags (usually filled with bulgur wheat or flaxseed, and then mixed with herbs) work well for relaxing tension in muscles and reducing achiness, especially ones infused with aromatherapy (such as lavender or rosemary). Unlike an acutely injured muscle, chronic muscle soreness benefits from the increased blood flow that heat provides. Apply the herbal bag for about 20 minutes at a time, up to five times per day. As an alternative, soak your chronically sore muscle(s) in a warm Epsom salt bath for about 20 minutes. The warm water improves blood circulation and the magnesium-rich salt works well to reduce muscle tension and pain. Applying moist heat to your sore muscle just prior to stretching it (see below) is a good idea in most instances because it makes muscles more pliable and less likely to tear further. Don't use dry heat, such as electric heating pads, on your sore muscles because you risk dehydrating the tissue and making the problem worse. Take pain medicine. Inflammation is a significant problem with acute muscle injuries, so taking over-the-counter non-steroidal anti-inflammatory drugs (NSAIDs) during the initial stages of the injury is a good strategy. Common NSAIDs include ibuprofen (Advil, Motrin), naproxen (Aleve) and aspirin, but they tend to be hard on stomachs, so limit their use to less than two weeks at a time. On the other hand, if your muscle soreness is chronic, then you can try acetaminophen (Tylenol) instead, which is much easier on your stomach, but can negatively impact your liver with longer-term use. If your sore muscle is also significantly tight or spasming, then consider taking a muscle relaxant (such as cyclobenzaprine), but never take them at the same time as NSAIDs or painkillers. Ask your doctor for a prescription. Keep in mind that aspirin and ibuprofen are not appropriate for young children, so consult your doctor before taking any medications or giving them to your kids. Stretch your sore muscle(s). Muscle stretching is often recommended as an injury prevention strategy, but it can also be used to help recover from muscle injuries (albeit with some caution and common sense). Once the initial soreness of the acute muscle injury settles down after a few days, do some light stretching just to keep the muscle pliable and to prevent it from spasming (strong, painful contractions). Start with two to three stretches daily and hold them for 15 to 20 seconds each while taking deep breaths. Stop stretching if the soreness significantly increases or the type of pain changes (from soreness to sharp pain, for example). Use the internet to find demonstrations of stretches that apply to your specific sore muscle(s), although make sure they are provided by reputable and trained sources, such as physiotherapists, chiropractors, athletic therapists, personal trainers and the like. Chronically sore muscles are likely even more in need of stretching (due to tightness), so increase to three to five times per day and hold for 30 seconds until the discomfort fades away and the muscle loosens up. If you stretch properly, you should not have more muscle soreness the next day. If you do, then it may be an indication you've overstretched and need to go a little easier next time. A common cause of overstretching issues is doing them while your muscles are cold. As such, make sure to get your blood flowing or apply moist heat to any muscle before you attempt to stretch it. Drink more water. If your sore muscle involves any degree of cramping, then your problem may be related to dehydration (not enough water in the muscle tissue). Playing sports or being active in general, particularly if the weather is hot and humid, can cause excessive water loss from sweating. If you're not diligent about replacing the loss of water and maintaining normal blood volume, then dehydration and muscle cramping can ensue. Dehydration also significantly increases the risk of muscle pulls and strains. As such, aim for eight 8-ounce glasses of filtered water on most days, and maybe a little more on the weekends during summertime. As a good indicator of dehydration, look at the color of your urine. Dark yellow can indicate dehydration, whereas colorless urine is usually an indication of normal hydration. When replenishing yourself, avoid beverages with caffeine (coffee, black tea, soda pop, energy drinks) — it acts as a diuretic and stimulates you to urinate more often. Fresh squeezed juice (citrus, carrot, tomato) is a great option because it also contains electrolytes — ionic mineral salts that are lost when you sweat. Sodium is the most important mineral, but calcium, magnesium and potassium are also important for muscle function. Get a professional massage. Deep tissue massage is helpful for muscle function in general because it reduces muscle tension and promotes better circulation, which are important factors for preventing strains, spasms and cramps. If your muscle soreness doesn't fade away after a few days of rest and using home remedies, then schedule a 30-minute massage with a registered massage therapist. Have the therapist focus on your sore muscle and all directly related muscles and allow them to go as deep as you can tolerate it without wincing. Your therapist may also use trigger point therapy that focuses on the injured muscle fibers. In terms of frequency, everybody's financial situation and muscle injury is unique. Some people may derive benefit and value from a single massage, others may seek it out multiple times per month. As an alternative, ask your partner or spouse to massage your sore muscle(s). There's lots of instructional videos on the internet that can teach the basics of massage and offer pointers, although it's no substitute for professional training. Always keep well hydrated after a massage in order to flush inflammatory by-products and lactic acid from the body. Failure to do so might lead to nausea or a mild headache. Consider some acupuncture. Acupuncture treatment is based on principles of traditional Chinese medicine and involves inserting very thin needles into specific energy points under your skin in efforts to reduce pain and inflammation. Acupuncture for muscle and joint soreness can be very effective, especially if it's done when acute symptoms first develop. Acupuncture works by triggering your body to release endorphins and serotonin (among other chemicals), which act to combat musculoskeletal pain. Acupuncture has a good safety record and is relatively affordable, so it's worth a try if your muscle soreness lingers and is not impacted by other treatments or approaches. There is mixed evidence that acupuncture is effective for relieving chronic muscle and joint issues, but there's many anecdotal reports that it can help. Realize that the acupuncture points used to reduce your soreness may not be located in or near the problematic muscle — some points can be in distant areas of the body. Acupuncture is practiced by more healthcare professionals than ever before, including some physicians, chiropractors, physical therapists and massage therapists — whoever you choose should be certified by the National Certification Commission for Acupuncture and Oriental Medicine. Get referred for physiotherapy. If your muscle soreness is recurring (chronic) and acerbated by weakness, poor posture, overuse and/or degenerative conditions (such as osteoarthritis), then you need to consider undertaking some physical therapy and muscle rehabilitation. A physical therapist can show you specific and tailored stretches and strengthening exercises for your chronically sore muscles. It may seem counterintuitive to exercise while you feel soreness, but chronically weak muscles often quit generating pain when they are strengthened and start to function normally. Physiotherapy is usually required two to three times per week for four to eight weeks to positively impact chronically sore muscle issues. In addition to strengthening exercises, physical therapists can also use therapeutic devices to treat your muscle soreness, such as electronic muscle stimulation (EMS), therapeutic ultrasound, infrared (heat) therapy and/or transcutaneous electrical nerve stimulation (TENS). EMS and TENS devices can be purchased from medical supply and rehabilitation stores (online too) and used at home. However, they should only be used under the supervision or advice of a healthcare professional. Good general muscle strengthening exercises include swimming, rowing and bouncing on a mini-trampoline. 
Rest and take it easy. Apply cold therapy for acute muscle soreness. Apply moist heat for chronic muscle soreness. Take pain medicine. Stretch your sore muscle(s). Drink more water. Get a professional massage. Consider some acupuncture. Get referred for physiotherapy. 