Hepatitis B

Hepatitis B (hep B) is a contagious liver infection that can be spread through bodily fluids and can pose serious health risks. Learn how you can prevent getting hep B.

Hep B is a contagious infection of the liver caused by a virus. For some people, hep B can pose serious health risks, including severe scarring of the liver (called cirrhosis) and liver cancer.

The hep B virus is transmitted through blood, semen, and other bodily fluids. Hep B is easily spread through sex or through sharing needles, syringes, and/or other injection equipment used for drugs, hormones, or steroids. You may also be at risk of getting hep B if you share items such as snorting straws, toothbrushes, or razors that may have blood on them. Pregnant people can pass the virus to their babies at birth, but transmission can be prevented by providing hep B immune globulin (a special type of medicine) and hep B vaccine to infants shortly after birth.

Some people who get hep B may have few or no symptoms and may never know they are infected. If people do feel sick, usually it’s within six months of becoming infected, though others may experience symptoms later in life. The virus can be passed to others even if the person who has hep B doesn’t feel sick or show symptoms.

Common symptoms include:

  • Loss of appetite
  • Fatigue
  • Nausea
  • Vomiting
  • Yellowing of the eyes or skin

Hep B is not spread by casual contact like hugging, coughing, sneezing, or sharing eating utensils.

Getting tested for hep B is key to preventing transmission and reducing your risk of serious illness.

All adults 18 years and older should be screened for hep B at least once in their lifetime using a triple panel test, which looks for different markers of hep B.

Although anyone can get hep B, some people are at higher risk and should be screened regularly (at least annually):

  • Men who have sex with men, especially with multiple sex partners
  • People who inject drugs or share needles, syringes, and/or other drug injection equipment
  • People with hep C
  • Sex partners of people with hep B
  • People who have sexually transmitted infections
  • People with HIV infection
  • People who live with someone who has hep B
  • People born in countries where hep B is common
  • Infants born to pregnant people with hep B

If you think you’ve been exposed, talk to your health care provider about testing for hep B, as well as hep A, HIV, hep C, and sexually transmitted infections (STIs). A blood test can detect hep B.

Looking for a health care provider? Find a health care provider near you.

In most adults, the hep B virus eventually goes away on its own without treatment. Once the virus has left the body, the person will be immune to hep B and can no longer pass it to others.

However, if the hep B virus stays in the body, it can become a chronic infection that can lead to cirrhosis or other serious conditions. There are medications available to manage chronic hep B, but it cannot be cured.

There is a safe and effective hep B vaccine. It’s given in three doses over a six-month period. If you’re under 30, there’s a good chance you’ve already been vaccinated, so talk to your health care provider.

Plan on getting the hep B vaccine? Be sure to ask your health care provider about the hep A vaccine, too.

The hep B virus can survive for long periods of time on surfaces, including objects and skin. Because it’s spread through direct contact with blood and body fluids that contain the virus, you can also help prevent transmission by:

  • Washing your hands with soap and water, especially after sex
  • Using condoms if you have oral, vaginal, or anal sex
  • Using a latex barrier for rimming
  • Using latex gloves for fingering or fisting
  • Disinfecting sex toys
  • Avoiding sharing drug injection equipment, including needles or syringes
  • Avoiding sharing razors, nail clippers, or nail scissors

Icon: Map Locator

Looking for sexual health services?

Find low- to no-cost sexual health services near you, like PrEP, STI testing, and more on the Service Locator Map.

Icon: Checkmark

Is PrEP right for you?

PrEP is a medication that helps prevent HIV. Take a short quiz to find out if it may be right for you.

Logo: Care That Fits You

Logo: Massachusetts Department of Public health

Brought to you by Massachusetts Department of Public Health Copyright © 2026

Logo: Care That Fits You

Logo: Massachusetts Department of Public health
Brought to you by Massachusetts Department of Public Health Copyright © 2026