Neck stiff is usually not a sign of serious health problems, but this can inhibit daily activity and make you difficult to sleep. The cause of neck stiffness may be associated with a variety of problems, which include poor posture while at work, incorrect sleeping position, muscle massage during exercise, anxiety, or other health problems. Try the following steps to relieve your stiff neck.
Using Hot and Cold Care
- Give damp heat to your neck. The heat will help relax the tense muscles,  and damp heat is better than dry heat, because it can seep into the neck more effectively.  Give heat to your back or neck for at least 20 minutes at a time, three times a day.
- Wet dampening pads (available at pharmacies) are the best option to provide heat to your neck, as the temperature can be adjusted and affixed for a longer time. Alternatively, use hot water bottles, or take a bath, or soak in hot water.
- Put a hot towel around your neck. Put a small towel into a bowl full of hot water, or pour hot water all over the surface of the towel. Alternatively, put a towel into the clothes dryer for 5 – 7 minutes. So the towel is quite dry and the water does not drip, but it is still quite warm. Wrap a towel around your neck when it feels stiff or sore.
- Try using an ice pack to soothe your neck. Colding will relieve local pain and reduce lactate acid accumulation that can cause pain.  Use an ice pack and place it on the neck that hurts (usually behind the neck, just below your hairline). Leave the ice bag there for 10-15 minutes every 2 hours. 
- You can also try a more comfortable position when compressing your cold neck. Sit in a comfortable chair and lean your head. Place an ice pack between your shoulders and the base of your head. Bring your head back so that your neck benefits the cold temperature completely.
- Some experts assume that the ice will actually cause the neck increasingly stiff because the cold temperature makes your muscles to contract.  Try which one feels good to your neck.
- Use a cold compress to relieve acute pain within the first 48 -72 hours, and then replace it with a hot compress. 
Stretching Muscles to Relieve Stiffness in the Neck
- Bring your head back and forth. In most cases, neck stiffness can be quickly relieved by performing a series of exercises to reduce the tension caused by stiff or tense muscles. Stretch the muscles in front and behind your neck by bending your chin to your chest. Then lift your chin up. Repeat for a few minutes.
- If this exercise hurt, do not bend or lift your neck too far. Try to move it until it feels a bit stretched.
- Bend your head from one side to the other. Stretch the muscles next to your neck by bending your head from one shoulder to the other. Keep doing this until the pain subsides, and your muscles tension.
- Look your head from left to right. This is often the most painful movement when your neck is stiff, so do it slowly. Keep turning your head from left to right for a few minutes.
- Reduce severe physical activity. During the first few days after your neck stiffens, reducing physical activity is the right move.  This will help reduce symptoms and relieve the inflammation that you may experience. Avoid following exercise or exercise for the first 2 to 3 weeks after stiff neck:
- Soccer, hockey, rugby or sports with other high contacts
- Run or jog
- Sit up and lift your legs.
Knowing Time to Visit the Doctor
- Visit your doctor if you feel any pain that does not subside. Sometimes neck stiffness is a symptom of deeper problems, such as shifting of the spine or a pinched nerve. If you experience neck stiffness more than a few days, call your doctor to see if you need medical treatment. 
- Your doctor may give you anti-inflammatory injections. Cortisone injection can be administered directly at rigid neck points, and will reduce inflammation in the neck, which can be the cause of the stiffness. 
- Check your anxiety level. Neck stiffness can be caused by excessive tension in the body, which is often caused by excessive anxiety. If you feel your anxiety causes stiff neck, you may need to visit a doctor or counselor to talk about anxiety treatment. 
- Look for medical help if you are aware of severe symptoms. Neck stiffness is one of the main symptoms of meningitis, a serious bacterial disease that causes swelling around the brain.  Neck stiff can also indicate that you have a heart attack.  Seek medical help immediately if you experience any of the following symptoms:
- Nausea and vomiting.
- Difficulty touching your chin to your chest.
- Chest pain or pain in the left arm.
- If you have trouble sitting, standing, or walking, see your doctor immediately.
Using Pain Relief Drugs.
- Apply topical analgesic ointment. You can also relieve pain quickly using a mentile-containing balm or other ingredients that calm muscles and skin. Some of the famous types of balm are Icy Hot, Ben Gay and Aspercreme.
- You can also make your own analgesics. Melt 2 tablespoons of coconut oil together with 1 tablespoon beeswax in a small pan using medium heat. Add 5 drops of peppermint oil, and 5 drops of eucalyptus oil. Pour this mixture into a closed jar, like a small mason jar. Once cool, apply it to the neck and the area around it.
- Drink ibuprofen or aspirin. NSAIDs, or nonsteroidal antiinflammatory agents such as ibuprofen and aspirin have been shown to be effective pain reliever and sold freely. Be sure not to consume more than the recommended dose.
- Try muscle relaxant drugs. Muscle relaxants are useful for relaxing the muscles and relieving stiff or tense necks. It should only be used as a temporary reliever, and is best drunk before you sleep.  Use muscle relaxants if other methods such as muscle stretching, and hot or cold therapy do not work.
- Muscle relaxants may also contain other medicinal ingredients. Read the instructions carefully to be sure to take the right dose.
Adjusting Sleep Settings
- Choose a pillow that can support your head. If you occasionally wake up with a stiff neck, maybe the cause is your pillow. Depending on how you sleep, choose a pillow that will reduce the stiffness of the neck.  The memory foam pillow is a good choice, as it can hold your head well, so your neck can be completely relaxed during sleep.
- The person sleeping sideways should find a pillow that can keep his head in a horizontal position, and not slump to the mattress.
- The person sleeping on his back should use a pillow that keeps his head remained horizontal as well as not leaning his chin toward his chest.
- Replace your feather pillow after one year. Pillows containing feathers can support the neck well, but will lose its shape after about 1 year. If you have been using a pillow during this time, and have neck stiffness, consider buying a new pillow. 
- Try to sleep without a pillow. Many doctors recommend sleeping without a pillow for several nights after your neck is stiff.  This method may help relieve symptoms and prevent neck stiffness caused by misalignment.
- Make sure your mattress is hard enough. Your mattress may not be strong enough to support your neck and spine. If you’ve been using that mattress for years, it may be time to buy a new mattress.
- You can also try flipping your mattress, which should be done at any given time to make sure its shape is not damaged. Be sure to follow the manufacturer’s instructions, as some types of mattresses (eg mattresses with pillows on it) should not be reversed.
- Avoid sleeping on your stomach. Sleeping on the stomach can have a major effect on the neck and spine, as your neck will rotate to one side all night long. Try to sleep sideways or on your back. Even if you change your position to lying on your backside, the time you spend sleeping on your stomach will be shorter than if you started sleeping in such a position. 
- Try to sleep for 7 – 8 hours every night. Enough rest allows your body to recover. Sleep disturbances such as waking at night, or having trouble sleeping, can make the neck pain worse, because your body does not have enough time to relax and recover itself. Try to sleep through the night every day. 
Doing Massage and Alternative Treatment
- Massage your neck. Massage therapy is one of the best ways to relieve stiff neck. If you are massaging your own neck, use this technique:
- Warm the back of your neck by rubbing your hands up and down.
- With gentle pressure, use your fingertips to rub the neck in a circular motion. Focus on the most rigid parts, but rub your entire neck to relieve the stiffness. 
- Repeat this up and down motion in your neck for a few minutes.
- Visit a massage therapist. The massage therapist will work with you to determine the tense parts of the body. Although your neck is tense, inside your body there may be other tensions that eventually accumulate in your neck.
- Check your health insurance to see if the massage is included in a guaranteed treatment.
- Try acupuncture. Acupuncture is a Chinese treatment to relieve pain and other disorders by inserting fine needles at certain points. Although some people doubt the effectiveness of acupuncture, many chronic neck stiff sufferers benefit from this treatment. 
- Visit acupuncturists to consult and ask specifically about pain and neck stiff treatment.
Trying Other Home Maintenance
- Drink magnesium supplements. Although it has not been scientifically proven to help relieve rigid or neck pain, magnesium has been regarded as an effective relaxation therapy for many patients with severe muscle pain. Try taking magnesium supplements.
- The recommended daily dose for magnesium supplements is between 310 mg to 420 mg, depending on the age and sex of the sufferer.  Do not exceed the recommended daily dose.
- Try taking epsom salt baths. Epsom salts, or magnesium sulfate, are common additives used in many hot-water pools, although scientific evidence suggests that epsom salts have no effect that can help relieve muscle aches. 
- Try Chinese scrape therapy, or Sha Cave. As a very well-known practice in China and Vietnam, scrape is done using a dull spoon to rub the back to bruising. This action is expected to smooth the blood flow in that section, and remove toxins or other unhealthy elements from there. Sha’s cave began to be scientifically tested, and sometimes gave positive results. 
- The Sha Cave is not a treatment that escapes the debate. Because it causes bruises, these treatments look scary, and may not feel soothing or give results to some patients.
- Care Sha Cave must be done carefully; Communicate with your therapist when his movements are not comfortable or rough on your skin. You certainly do not want to end treatment with a wounded skin and feel uncomfortable.
Preventing the Rigid Return of the Neck
- Organize your workplace to be ergonomic. Many people suffer from neck stiffness because the workplace is not ergonomic. Put your chair in such a way that your feet can touch the floor and your arms can lean against the table.
- If you have a computer monitor, make sure it lies parallel to your eyes.
- Do not sit too long. If you sit in a chair all day, or spend a lot of time in the car, take a break intermittently. Move so that your muscles have a chance to stretch themselves after stiff for hours.
- Do not see the phone too often down. Bending your neck constantly can hurt your neck slowly. So, it’s better to hold the phone or tablet in front of you parallel to the eye.
- Do not wear heavy bags on one shoulder only. Carrying a heavy load on one shoulder will make one side of your body tighter than the other. Your neck and back will balance this load causing stiff neck. Wear a backpack or wheeled suitcase instead.
- Use the right sports techniques. Lifting is one of the common causes of neck stiffness. You can make your muscles tense, or make your nerves squeezed if you do not use a safe technique. Exercise with the instructor to make sure you are using the correct technique.
- Do not try to lift more weights than you can afford. Look for loads that match your body’s shape and level of strength.
- Do not lift loads too much every week. Your muscles need to recover after each exercise.