As your periods become more erratic and then stop, you’ll see a number of changes in your body and health. Although every woman is different, symptoms like hot flashes, mood changes, trouble sleeping, and weight gain are normal during this time.

Between 25 and 45 percent of postmenopausal women say they have pain during sex. When sex hurts, you may avoid it, which could affect your relationship.

Sex is painful during menopause due to a lack of estrogen. This hormone normally stimulates the release of natural lubricants and helps replenish the vaginal lining by growing new cells. When you go into menopause, your body gradually produces less estrogen.

Without estrogen, the vaginal lining thins, shrinks, and dries out. It also becomes less elastic. Your doctor may call this “vulvovaginal atrophy.”

When the tissue inside your vagina thins, penetration can become painful. Pain during sex is called dyspareunia. The pain can feel sharp or burning. If the inside of the vagina thins enough, it can tear or bleed during sex.

Painful sex can make you worry. Anxiety reduces lubrication even more and may cause you to clench the muscles of your vagina during sex. If sex becomes too painful, you may avoid it entirely.

Sex stimulates blood flow to the vagina, which keeps the tissues healthy. When you avoid sex, the lining of your vagina may become even thinner and less elastic. Sometimes the pain eases up once you’ve completed menopause. In some women, it doesn’t go away.

Many treatments are available to make sex more comfortable and pleasurable again. Ask your gynecologist which of these options might be best for you.

These products may be the first treatment you try to prevent pain during sex. Lubricants come in a liquid or gel, and they can help with mild dryness.

Lubricants prevent pain by reducing friction. You apply them to your vagina or your partner’s penis right before you have sex.

If you aren’t fully in menopause or you use condoms with your partner, you may want to use a water-based lubricant. Oil-based lubricants can damage condoms and make them less effective.

Moisturizers also reduce friction during sex. But because they penetrate into the skin, their effects last longer. A moisturizer like Replens can keep working for three or four days.

For more severe dryness and pain that doesn’t improve with a moisturizer or lubricant, your gynecologist may prescribe low-dose topical estrogen.

Estrogen improves the thickness and flexibility of vaginal tissues and increases blood flow. Because the hormone goes directly into the vagina, it avoids some of the body-wide side effects of estrogen pills. Estrogen comes in a cream, tablet, flexible ring, or insert.

Vaginal estrogen cream is sold under brand names like Premarin and Estrace. You apply it to your vagina two to three times a week. The vaginal ring (Estring) is inserted into the vagina. It can stay in for up to three months. The vaginal tablet (Vagifem) is placed into the vagina twice a week with an applicator or your finger.

Some women prefer the ring or tablet to cream because it’s less messy. Up to 93 percent of women who use low-dose vaginal estrogen say it significantly relieves their pain during sex.

Ospemifene is the only FDA-approved non-hormonal treatment for painful sex due to menopause. It acts like estrogen to thicken the vaginal lining, but it doesn’t increase the risk for breast or uterine cancer like estrogen pills can. In studies, ospemifene improved both dryness and pain. It worked as well as or better than topical estrogen.

Ospemifene comes in a pill that you take once a day. The main side effect is hot flashes. It may also slightly increase the risk of blood clots and stroke.

If estrogen creams or inserts haven’t helped with your pain, your doctor might recommend taking estrogen pills. Hormone therapy can also relieve hot flashes and other side effects of menopause.

Hormone pills do have risks, though. They can cause side effects such as:

  • headache
  • breast tenderness
  • bloating
  • nausea
  • weight gain
  • vaginal bleeding

Long-term estrogen use may increase the risk of uterine cancer and breast cancer. If you have a family history of these cancers, ask your doctor whether it’s safe for you to take estrogen by mouth.

Pain during sex isn’t always due to atrophy. It could also be a sign of these conditions:

Vestibulodynia. The vestibule is the area where the vulva — the outer parts of the vagina including the clitoris, clitoral hood, and labia — connects with the vagina. In some women, the vestibule becomes very sensitive to touch. Having sex or inserting a tampon is very painful. Doctors can treat this condition with local anesthetic creams or gels, physical therapy, and mental health counseling.

Vulvodynia. This condition causes pain or burning in the vulva without any obvious cause. About 60 percent of women with vulvodynia are unable to have sex because of the pain. Treatments include topical anesthetics, physical therapy, and mental health counseling.

Vaginismus. In this condition, the muscles around the vagina contract painfully during sex, or whenever something is inserted into the vagina. It may be triggered by fear after a traumatic experience. Treatments include a dilator to widen and relax the vagina and physical therapy.

Cystitis. Bladder inflammation can cause pain during sex because the bladder sits right on top of the vagina. At least 90 percent of people interviewed by the International Cystitis Association (ICA) said interstitial cystitis negatively affected their sex life. Treatments for cystitis include medication, nerve blocks, and physical therapy. Relaxation techniques, heat, or cold may also help relieve discomfort.

Thinning and dryness of the vaginal lining can make sex more painful in menopause. If it hurts to be intimate with your partner, see your gynecologist or primary care doctor for advice.

Lubricants, moisturizers, and various forms of estrogen treat dryness. Your doctor can also check to see whether another condition is causing your pain.