Conditional Probability Calculator

Calculate conditional probability or a Bayes update, with substituted formulas and an event tree.

On-device No sign-up Free to use

Calculate result controls

Showing an example. Edit to see your own.

?

Used by joint mode. A probability from 0 to 1.

?

Used by joint mode. Must be greater than zero and at least P(A and B).

?

Used by Bayes mode. A probability from 0 to 1.

?

Used by Bayes mode. A probability from 0 to 1.

?

Used by Bayes mode. A probability from 0 to 1.

Processed in your browser. Your inputs stay on this device.

Result

Showing an example.

If A and B occur together with probability 0.2 and B has probability 0.5, find the share of B outcomes that also satisfy A.

P(A given B) = 0.4.
Answer: 0.4
Formula: P(A given B) = P(A and B) / P(B); P(A given B) = 0.2 / 0.5 = 0.4

https://usefreetools.net/conditional-probability-calculator · 20 November 2026

Was this helpful?

How to use Conditional Probability Calculator

  1. Choose Conditional probability from a joint probability or Bayes update from supplied assumptions.
  2. In joint mode, enter P(A and B) and P(B). P(B) must be positive and at least as large as the joint probability.
  3. In Bayes mode, enter the prior P(A), P(B given A), and P(B given not A). The joint-mode fields are ignored.
  4. Enter probabilities as decimals from 0 to 1, such as 0.2 for 20%. Review the substituted formula and event tree, then download probability-tree.svg if useful.

Example: Conditional Probability Calculator

If A and B occur together with probability 0.2 and B has probability 0.5, find the share of B outcomes that also satisfy A.

You add
Calculation: Conditional probability from a joint probability P(A and B): 0.2 P(B): 0.5 Prior P(A): 0.1 P(B given A): 0.8 P(B given not A): 0.05
You get
P(A given B) = 0.4. Answer: 0.4 Formula: P(A given B) = P(A and B) / P(B); P(A given B) = 0.2 / 0.5 = 0.4

Options

Joint-event mode
Divide the entered P(A and B) by P(B). The joint probability cannot exceed the conditioning probability.
Bayes inputs
Enter the prior and the likelihood of the evidence under both alternatives. These inputs are assumptions supplied by you.

Supported inputs and limits

  • Enter plain decimals, with at most 64 characters, 25 digits and 12 fractional places per number.
  • Probabilities must be between 0 and 1.
  • A zero conditioning denominator is undefined and refused.
  • Joint mode requires P(A and B) ≤ P(B).
  • Bayes mode uses A and not A as exhaustive alternatives, with the prior and likelihoods you supply.
More details

It does not derive those inputs from observations.

The tree shows the computed contributions to B; it is not additional evidence or a diagnostic conclusion.

Where your input is processed

This tool does not upload your inputs. See the limits for anything saved on your device.

Reverse conditional probabilities are different questions

P(B given A) is not usually P(A given B). The prior and alternative likelihood affect the Bayes result. A zero conditioning probability makes the ratio undefined; the page refuses it instead of returning a misleading zero.

Questions about Conditional Probability Calculator

Why does a zero conditioning probability fail?

Division by zero cannot define this conditional probability. The result is undefined rather than zero.

Are likelihood and posterior the same?

No. Likelihood describes the evidence under a hypothesis. The posterior also depends on the prior and alternative likelihood.

Can this assess a real-world claim for me?

It applies the probabilities you enter. Choosing credible inputs and checking the model remain separate tasks.

Page updated · Project managed by Tony Hines · Report a problem with Conditional Probability Calculator