Anion gap calculator

Enter electrolyte results from a blood test to calculate the anion gap, which helps interpret metabolic acidosis.

Loading the tool…

Processing and privacy: The result is calculated inside your browser and your data is not sent to any server.

How to use it

  1. Enter sodium (na), chloride (cl), bicarbonate (hco3), potassium k (optional), albumin (optional) and albumin unit.
  2. The result appears straight away and updates as you edit.
  3. Copy the result, or copy a link that keeps the same values to share it.

How it is calculated

Anion gap = Na - (Cl + HCO3). With potassium: Na + K - (Cl + HCO3). Albumin-corrected = gap + 2.5 × (4.0 - albumin in g/dL).

Example

Inputs: Sodium (Na) = 140 mmol/L, Chloride (Cl) = 104 mmol/L, Bicarbonate (HCO3) = 24 mmol/L, Albumin unit = g/dL. Result: Anion gap: 12 mmol/L.

Limits and caveats

  • The normal range differs between labs and analyzers, so compare with the range printed on your report.
  • The albumin correction is an approximation of 2.5 per 1 g/dL.
  • An educational estimate that does not replace assessment by a doctor or pharmacist.

Questions about this tool

What is the anion gap used for?

It helps sort the causes of metabolic acidosis; a high gap points to extra acids such as ketones or lactate.

Why correct for albumin?

Albumin is the largest unmeasured anion, so low albumin lowers the gap and can hide a high gap acidosis.

Should I enter potassium?

It is optional. Many labs calculate the gap without it, and adding it raises the result by the potassium value.