Skip to main content
v2026.11,858 entries · CC-BY 4.0

Vaccine Efficacy: Formula, Worked Example and Interpretation

Vaccine efficacy is 1 minus the risk ratio. Formula, two worked examples, a reading table, and Excel, R and Python code.

Written and maintained by CASRAI Editorial Board

Last updated

Vaccine efficacy (VE) is the percentage reduction in the risk of disease among vaccinated people compared with unvaccinated people. It is calculated as 1 minus the risk ratio, so a vaccine efficacy of 80% means the vaccinated group had an 80% lower risk of disease than the unvaccinated group. This guide gives the formula, two worked examples with the arithmetic shown, a table for reading the result, and snippets for Excel, R and Python.

What is vaccine efficacy?

The CDC’s Principles of Epidemiology describes vaccine efficacy as measured by “calculating the risk of disease among vaccinated and unvaccinated persons” and then “determining the percentage reduction in risk of disease among vaccinated persons relative to unvaccinated persons.” It is a relative risk expressed as a reduction, which is why it also appears under the names relative risk reduction and, for the observed-in-the-field version, vaccine effectiveness.

The result is a comparison of two risks. It says nothing on its own about how common the disease is, and it is not the share of vaccinated people who are protected. The next sections show why.

Vaccine efficacy formula

There are two equivalent forms.

VE = (Ru − Rv) / Ru, which can also be written VE = 1 − RR, where RR = Rv / Ru.

  • Ru: risk of disease among unvaccinated (or placebo) participants, calculated as cases divided by the number of people followed in that group.
  • Rv: risk of disease among vaccinated participants, calculated the same way.
  • RR: the risk ratio, Rv / Ru. See absolute risk reduction, relative risk and NNT for how it differs from the risk difference.
  • VE: the proportion of risk removed, usually multiplied by 100 and reported as a percentage.

Both groups must be compared over the same follow-up period, and the risks must use the same case definition in each group.

Worked example: the CDC varicella calculation

The CDC’s lesson on vaccine efficacy works through a varicella outbreak with a risk of disease of 42.9 among the unvaccinated and 11.8 among the vaccinated (the lesson reports these two risks; the same units apply to both, so they cancel). Using the first form of the formula:

VE = (42.9 − 11.8) / 42.9 = 31.1 / 42.9 = 0.7249, reported by the CDC as 72%.

Using the second form: RR = 11.8 / 42.9 = 0.2751, which the CDC rounds to 0.28, and VE = 1 − 0.28 = 0.72, or 72%. Both routes agree. The CDC’s reading is that “the vaccinated group experienced 72% fewer varicella cases than they would have if they had not been vaccinated.”

Worked example with raw counts

This example is constructed for illustration and does not describe a real trial. Suppose 1,000 participants receive a vaccine and 1,000 receive a placebo, and both groups are followed for the same period. There are 30 cases in the vaccinated group and 120 in the placebo group.

  1. Rv = 30 / 1,000 = 0.03 (3.0%)
  2. Ru = 120 / 1,000 = 0.12 (12.0%)
  3. RR = 0.03 / 0.12 = 0.25
  4. VE = 1 − 0.25 = 0.75, or 75%

Check with the other form: (0.12 − 0.03) / 0.12 = 0.09 / 0.12 = 0.75. The vaccinated group had a 75% lower risk of disease than the placebo group. The risk difference is 0.09, or 9 percentage points. That absolute figure is a separate quantity from VE and answers a different question, as the absolute versus relative risk guide explains.

How to interpret vaccine efficacy

WHO states the reading directly: an efficacy of 80% means that the vaccinated group had an 80% lower risk of developing disease than the unvaccinated group. Use that wording and avoid “80% of vaccinated people were protected.”

VE RR (1 − VE) What it means
0% 1.00 Risk among vaccinated equals risk among unvaccinated; no reduction.
50% 0.50 Vaccinated risk is half the unvaccinated risk.
75% 0.25 Vaccinated risk is one quarter of the unvaccinated risk (the example above).
80% 0.20 The vaccinated group had an 80% lower risk (WHO’s wording).
100% 0.00 No cases among vaccinated participants.
Below 0% Above 1.00 Vaccinated risk is higher than unvaccinated risk in the data.

Vaccine efficacy vs vaccine effectiveness

The CDC uses vaccine efficacy when a study is carried out under ideal conditions, for example in a clinical trial, and vaccine effectiveness when a study is carried out under typical field conditions, which are less tightly controlled. WHO draws the same line: efficacy is measured in controlled clinical trials, while effectiveness describes how well vaccines work in the real world. WHO also notes that effectiveness can differ from efficacy because exactly how effective vaccination will be cannot be predicted in advance.

The formula is the same; the study setting and the comparison group differ. Observational effectiveness studies often use designs such as the one described in the test-negative design guide.

Assumptions and common mistakes

  • Comparable groups. The formula treats the two groups as comparable apart from vaccination. In a randomised trial, randomisation supports that; in field studies, differences between vaccinated and unvaccinated people can distort the result.
  • Same follow-up and case definition. Both risks must cover the same period and count the same outcome.
  • Reading VE as the percent of people protected. VE is a reduction in risk, not a count of protected individuals. With 3.0% disease among vaccinated people in the example, it would be wrong to say 97% were “protected” and equally wrong to say 75% were.
  • Swapping the groups. Put the unvaccinated risk in the denominator. Reversing the two risks in the example gives −300%, a different and meaningless quantity.
  • Treating a point estimate as exact. Report an interval around the estimate where the study design supports one; see how to report confidence intervals and the confidence interval entry.

How to report vaccine efficacy (APA style)

State the groups, the case counts, the denominators and the estimate, and name the formula. An example sentence in APA style, using the constructed figures above:

Vaccine efficacy was 75%, calculated as 1 − RR, where the risk of disease was 3.0% (30/1,000) in the vaccinated group and 12.0% (120/1,000) in the placebo group.

Add the confidence interval and the method used to compute it when your analysis produces one.

How to calculate vaccine efficacy in Excel, R or Python

Excel

Put vaccinated cases in B2, vaccinated total in B3, unvaccinated cases in C2 and unvaccinated total in C3, then enter:

=1-(B2/B3)/(C2/C3)

With 30, 1000, 120 and 1000 the cell returns 0.75; format it as a percentage.

R

ve <- function(cases_v, n_v, cases_u, n_u) 1 - (cases_v / n_v) / (cases_u / n_u)
ve(30, 1000, 120, 1000)  # 0.75

Python

def ve(cases_v, n_v, cases_u, n_u):
    return 1 - (cases_v / n_v) / (cases_u / n_u)

print(ve(30, 1000, 120, 1000))  # 0.75

All three apply the formula VE = 1 − RR and return the same value for the worked example.

Frequently asked questions

What does 90% vaccine efficacy mean?

It means the vaccinated group had a 90% lower risk of disease than the unvaccinated group, so the risk ratio is 0.10. It does not mean that 90% of vaccinated people are protected.

What is the difference between vaccine efficacy and relative risk?

Vaccine efficacy equals 1 minus the relative risk. A relative risk of 0.28 corresponds to an efficacy of 72%. See the relative risk and odds ratio vs risk ratio pages for the underlying measures.

Can vaccine efficacy be negative?

Yes, as a calculation. If the risk among vaccinated participants is higher than among unvaccinated participants, RR is above 1 and VE falls below 0%.

Is vaccine efficacy the same as vaccine effectiveness?

No. The CDC and WHO reserve efficacy for controlled trial conditions and effectiveness for real-world conditions. The formula is shared.

Sources

Follow CASRAI

Research-administration guidance, standards updates and independent tool reviews.

Ask CASRAI · free to try

Ask about Vaccine Efficacy: Formula, Worked Example and Interpretation

Ask your first 2 questions free below. Subscribers get 150 a day for $29 a month.

An AI assistant specialized in research administration. It cites the sources behind every answer, labels web answers and says when it can't answer.

Answers draw on CASRAI's guides and dictionary plus the federal and funder documents we index: Federal Register, Grants.gov, Regulations.gov and UKRI.

Works on this site and inside Claude, Cursor and the AI tools you already use.

Everything CASRAI publishes — this page, the dictionary, the guides and the news — stays free to read, with no account and no card.

Referenced across the research world

University of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logoUniversity of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logo
  • University of Cambridge logo
  • Columbia University logo
  • Crossref logo
  • University of Edinburgh logo
  • Harvard University logo
  • University of Oxford logo
  • Princeton University logo
  • Stanford School of Medicine logo
  • University College London logo
  • ORCID logo

View CASRAI adoption →

Ask CASRAI · Regulatory Radar

Research-admin question? Get an answer that links its sources.

An AI assistant specialized in research administration. Every answer links its sources to check before you act. 2 questions free, no account. $29/month after.

  • Answers draw on CASRAI's guides and dictionary plus the federal and funder documents we index: Federal Register, Grants.gov, Regulations.gov and UKRI.
  • Every answer numbers its sources and links each one, so you can check the source yourself.