Hepatitis B is caused by a virus called HBV
Hepatitis B virus (HBV) is the pathogen responsible for hepatitis B infection. It is a DNA virus — meaning its genetic material is made of DNA rather than RNA — and it belongs to a family of viruses called hepadnaviruses. HBV attacks the liver and can cause both short-term and long-term infection depending on when a person is infected and how their immune system responds.
The virus spreads through contact with infected blood or body fluids. Unlike hepatitis A, which spreads through contaminated food or water, HBV requires direct exposure to blood or certain body fluids to transmit from one person to another. This is why the routes of transmission are specific and predictable, and why prevention through vaccination is highly effective.
Key Takeaways
- Hepatitis B virus (HBV) is a DNA virus that infects liver cells and can cause lifelong infection if not cleared by the immune system.
- HBV spreads through blood-to-blood contact, sexual contact, and from mother to child during birth — not through casual contact, food, or water.
- The virus can survive outside the body for up to seven days on a surface, which is why healthcare settings and shared equipment pose a risk.
- A vaccine that prevents HBV infection is available and is part of routine childhood immunizations in most countries.
- People infected with HBV may have no symptoms but can still transmit the virus to others, making testing the only way to know infection status.
How HBV enters and damages liver cells
When HBV enters the bloodstream, it travels to the liver and attaches to liver cells using a surface protein. The virus then enters the cell and uses the cell's machinery to make copies of itself. As the virus replicates, it damages the liver cells and triggers an immune response.
In adults, the immune system usually clears the infection within six months — this is called acute hepatitis B. In infants and young children, however, the immune system is less likely to clear the virus, and infection becomes chronic. Chronic HBV infection means the virus remains in the liver for life and continues to damage liver tissue over time, potentially leading to cirrhosis or liver cancer.
The main routes HBV spreads from person to person
HBV spreads through direct contact with infected blood or body fluids. The most common routes are:
- Blood-to-blood contact: Sharing needles, syringes, or other injection equipment; needle-stick injuries in healthcare settings; or sharing personal items like razors or toothbrushes that may cause tiny cuts.
- Sexual contact: The virus is present in semen and vaginal fluids, so unprotected sex with an infected person carries risk.
- Mother to child: An infected pregnant person can pass HBV to their baby during birth, though not usually during pregnancy itself.
- Blood transfusion or organ transplant: Before screening protocols were in place, this was a major route; today it is rare in countries with blood screening programs.
HBV does not spread through casual contact like shaking hands, hugging, sharing food or drinks, coughing, or sneezing. You cannot get hepatitis B from touching an infected person or sharing a workplace or classroom with them.
Why HBV can survive on surfaces and what that means
HBV is more stable than some other viruses and can survive on a dry surface for up to seven days. This is why healthcare workers and people with occupational exposure to blood — such as those in emergency services, laboratories, or tattoo and piercing studios — face higher risk. The virus can enter the body through a cut or abrasion on the skin, even a microscopic one.
In healthcare settings, this is why strict protocols exist for handling blood and body fluids, sterilizing equipment, and disposing of needles. In community settings, the risk from environmental surfaces is very low because the virus needs a direct route into the bloodstream. Touching dried blood on a surface poses minimal risk unless you have an open wound on your hand.
The difference between acute and chronic HBV infection
When someone is first infected with HBV, they have acute hepatitis B. During this phase, the virus is replicating rapidly and the immune system is mounting a response. Some people develop symptoms like fatigue, jaundice (yellowing of the skin and eyes), abdominal pain, and dark urine. Others have no symptoms at all.
In most adults, the immune system clears the virus within six months and the person recovers completely. They develop immunity and cannot be infected again. However, in infants and young children — and in some adults — the immune system does not clear the infection. The virus persists in the liver, and the person becomes a chronic carrier. Chronic infection can last decades and may eventually cause cirrhosis, liver failure, or liver cancer, though many people with chronic HBV never develop severe liver disease.
Testing and knowing your HBV status
Because many people with HBV infection have no symptoms, the only way to know if you are infected is through a blood test. The test looks for HBsAg (hepatitis B surface antigen), which indicates current infection, and anti-HBs (hepatitis B surface antibody), which indicates immunity from vaccination or past infection.
Testing is recommended for anyone with risk factors — including people who inject drugs, those with multiple sexual partners, healthcare workers, people born in countries with high HBV rates, and anyone who has had a needle-stick injury. Pregnant people are also tested routinely so that preventive measures can be taken at birth if needed. If you are unsure whether you have been vaccinated or tested, your primary care provider can review your medical history and recommend testing if appropriate.
Prevention through vaccination
The hepatitis B vaccine is one of the most effective vaccines available, preventing infection in more than 95 percent of people who receive the full series. The vaccine teaches the immune system to recognize HBV and fight it off before infection takes hold. It contains no live virus and cannot cause hepatitis B.
The vaccine is given as a series of shots over several months. Infants typically receive their first dose within 24 hours of birth, with additional doses at one month and six months. Older children and adults who were not vaccinated as infants can receive the vaccine at any age. If you are uncertain about your vaccination status, a blood test can determine whether you are immune, and you can be vaccinated if needed.
Frequently Asked Questions
Can you get hepatitis B from sharing a toothbrush or razor?
Yes, if the toothbrush or razor causes bleeding in the mouth or on the skin. HBV in blood can enter through cuts or sores. This is why people with hepatitis B are advised not to share these items. The risk is low if there are no cuts, but it is not zero.
If someone has hepatitis B, can they prepare food safely?
Yes. HBV does not survive in the digestive system and cannot be transmitted through food or saliva. An infected person can prepare food safely as long as they do not have open wounds on their hands that could bleed into the food.
How long does it take for symptoms to appear after HBV exposure?
The incubation period — the time between exposure and symptom onset — is typically 45 to 180 days, though it can be shorter or longer. Many people never develop symptoms at all, even during acute infection. This is why testing is important if you think you may have been exposed.
Can hepatitis B be cured?
Acute hepatitis B usually clears on its own without treatment. Chronic hepatitis B cannot be cured, but antiviral medications can slow or stop the virus from replicating and reduce liver damage. Treatment decisions depend on how much liver damage has occurred and how active the virus is.
Is the hepatitis B vaccine safe for people with allergies?
The vaccine is safe for most people. If you have a severe allergy to any vaccine component — particularly yeast, since the vaccine is made using yeast — tell your healthcare provider before vaccination. Alternative formulations may be available.