Skip to main content

Relative Risk Calculator

Ready to calculate
Risk Ratio (RR).
ARR & NNT.
Epidemiological Analysis.
100% Free.
No Data Stored.

How it Works

01Enter 2×2 Table Data

Provide events and totals for both exposed and unexposed groups.

02Compute Group Risks

Risk in each group = events / total. Compared as a ratio.

03Get Relative Risk (RR)

RR = Risk(exposed) / Risk(unexposed). RR > 1 means increased risk.

04ARR & NNT

Absolute risk reduction and number needed to treat for clinical context.

Introduction

Relative risk (RR), also called the risk ratio, compares the probability of an outcome occurring in an exposed group to the probability in an unexposed (control) group. It is one of the most important effect size measures in epidemiology, clinical research, and public health — quantifying how much more (or less) likely an outcome is given a particular exposure or treatment.

The relative risk calculator takes four inputs from a 2×2 contingency table: the number of events and non-events in both the exposed and unexposed groups. From these, it computes the risk in each group, the relative risk, the absolute risk reduction (ARR), the number needed to treat (NNT), and the attributable risk.

A relative risk of 1.0 means no difference between groups. RR > 1 indicates increased risk in the exposed group; RR < 1 indicates reduced risk (protective effect). For example, RR = 2.0 means the exposed group has twice the risk of the outcome compared to the unexposed group.

Relative risk is used in cohort studies and randomized controlled trials (RCTs), where participants are followed over time to observe who develops the outcome. It is distinct from the odds ratio (OR), which is used in case-control studies and logistic regression.

Understanding relative risk is essential for evaluating vaccine effectiveness, drug efficacy, occupational hazard exposure, lifestyle risk factors, and many other public health interventions. This calculator simplifies the 2×2 table calculations and provides all key epidemiological measures in one place.

The formula

Risk in Exposed Group:
RE = a / (a + b)

Risk in Unexposed Group:
RU = c / (c + d)

Relative Risk:
RR = RE / RU

Absolute Risk Reduction (ARR):
ARR = RU − RE (for protective exposures)

Number Needed to Treat (NNT):
NNT = 1 / ARR

2×2 Table:
| | Outcome+ | Outcome− |
|Exposed| a | b |
|Unexposed| c | d |

Real-World Example

Calculation In Practice

Example: Vaccine Efficacy Study
  • Vaccinated with COVID: 10 out of 500 (a=10, b=490)

  • Unvaccinated with COVID: 80 out of 500 (c=80, d=420)
  • Risk vaccinated = 10/500 = 0.02 (2%)
    Risk unvaccinated = 80/500 = 0.16 (16%)

    RR = 0.02 / 0.16 = 0.125

    Interpretation: Vaccinated individuals have 87.5% lower risk.

    ARR = 0.16 − 0.02 = 0.14 (14%)
    NNT = 1 / 0.14 = 7.1 (vaccinate 7.1 people to prevent 1 case)

    Typical Use Cases

    1

    Clinical Trials

    Measure treatment efficacy by comparing event rates in treatment vs control groups.
    2

    Vaccine Studies

    Calculate vaccine efficacy as 1 − RR, expressing the percentage reduction in disease risk.
    3

    Occupational Health

    Assess the increased risk of disease among workers exposed to specific hazards.
    4

    Nutritional Epidemiology

    Compare disease risk between groups with different dietary habits or exposures.
    5

    Public Health Policy

    Use NNT to evaluate cost-effectiveness of preventive health interventions.

    Technical Reference

    Confidence Interval for RR (log method):
    ln(RR) ± 1.96 × √(1/a − 1/(a+b) + 1/c − 1/(c+d))
    CI = e^[ln(RR) ± margin]

    Vaccine Efficacy:
    VE = (1 − RR) × 100%

    Attributable Risk (AR):
    AR = RE − RU (excess risk due to exposure)

    Population Attributable Risk (PAR):
    PAR = (prevalence of exposure × AR) / overall risk

    RR vs Odds Ratio:

  • RR: ratio of risks (probabilities)

  • OR: ratio of odds

  • For rare outcomes: OR ≈ RR
  • Key Takeaways

    Relative risk is a clear, intuitive measure of effect size in epidemiological and clinical research. When RR > 1, the exposure increases risk; when RR < 1, it is protective. When RR = 1, exposure has no effect on risk. Always report confidence intervals alongside relative risk — a wide CI spanning 1.0 means the result may not be statistically significant.

    For rare outcomes (<10% prevalence), odds ratios approximate relative risks. For common outcomes, relative risk is preferable because odds ratios tend to exaggerate effect sizes. The NNT derived from absolute risk reduction is particularly useful for clinical decision-making and policy evaluation.

    Remember: relative risk is a ratio of probabilities, not a ratio of counts. Ensure your inputs correctly populate the 2×2 contingency table before interpreting results.

    Frequently Asked Questions

    What is relative risk?
    Relative risk (RR) is the ratio of the probability of an outcome in the exposed group to the probability in the unexposed group. RR=1 means no difference; RR>1 means increased risk; RR<1 means reduced risk.
    How is relative risk different from odds ratio?
    Relative risk compares probabilities directly (a/n₁ ÷ c/n₂). Odds ratio compares odds (a/b ÷ c/d). For rare outcomes, they are similar, but for common outcomes, OR tends to exaggerate risk relative to RR.
    What does RR = 0.5 mean?
    RR = 0.5 means the exposed group has half the risk of the outcome compared to the unexposed group — a 50% risk reduction.
    What is the number needed to treat (NNT)?
    NNT = 1 / ARR. It represents how many patients need to receive a treatment to prevent one additional bad outcome. Lower NNT means more effective treatment.
    How do I interpret a confidence interval for RR?
    If the 95% CI for RR does not include 1.0, the result is statistically significant at α=0.05. A CI spanning 1.0 means we cannot rule out that exposure has no effect.
    What is absolute risk reduction (ARR)?
    ARR = risk in control − risk in treated. It quantifies the absolute decrease in risk due to the intervention, complementing the relative measure (RR).
    Can relative risk be used in case-control studies?
    No. Relative risk cannot be directly calculated from case-control studies because the proportion of exposed/unexposed individuals is set by the researcher. Use odds ratio for case-control data instead.
    What is vaccine efficacy?
    Vaccine efficacy = (1 − RR) × 100%. A vaccine with RR = 0.1 has 90% efficacy — it reduces disease risk by 90% compared to unvaccinated individuals.
    What is attributable risk?
    Attributable risk (AR) = risk in exposed − risk in unexposed. It quantifies the excess risk due to the exposure itself, assuming the relationship is causal.
    When is relative risk preferred over odds ratio?
    Relative risk is preferred for prospective cohort studies and RCTs. It is more intuitive and directly interpretable as a ratio of probabilities. Use OR when the outcome is rare or in case-control studies.

    Author Spotlight

    The ToolsACE Team - ToolsACE.io Team

    The ToolsACE Team

    Our specialized research and development team at ToolsACE brings together decades of collective experience in financial engineering, data analytics, and high-performance software development.

    Statistical AnalysisSoftware Engineering Team