Hepatitis B is a DNA virus that infects liver cells and can cause both acute and chronic disease. It is believed that both viral and host factors are responsible for determining whether the infection is cleared or becomes chronic. Here we investigate the mechanism of protection by developing a mathematical model of the antibody response following hepatitis B virus (HBV) infection. We fitted the model to data from seven infected adults identified during acute infection and determined the ability of the virus to escape neutralization through overproduction of non-infectious subviral particles, which have HBs proteins on their surface, but do not contain nucleocapsid protein and viral nucleic acids. We showed that viral clearance can be achieved for high anti-HBV antibody levels, as in vaccinated individuals, when: (1) the rate of synthesis of hepatitis B subviral particles is slow, (2) the rate of synthesis of hepatitis B subviral particles is high but either anti-HBV antibody production is fast, the antibody affinity is high, or the levels of pre-existent HBV-specific antibody at the time of infection are high, as could be attained by vaccination. We further showed that viral clearance can be achieved for low equilibrium anti-HBV antibody levels, as in unvaccinated individuals, when a strong cellular immune response controls early infection. 