Skip to the anion gap calculator

Anion Gap Calculator

Free serum anion gap calculation from Na⁺, Cl⁻ and HCO₃⁻ — with optional potassium, corrected anion gap for albumin, delta gap / delta ratio, and a built-in urine anion gap calculator.

Serum anion gap calculator

Sodium (Na⁺)
mEq/L

mEq/L = mmol/L for Na⁺, Cl⁻, HCO₃⁻ and K⁺.

Chloride (Cl⁻)
mEq/L
Bicarbonate (HCO₃⁻)
mEq/L

Use venous/arterial HCO₃⁻ or total CO₂ from the chemistry panel.

Albumin (optional)
g/dL

Enables anion gap albumin correction formula.

Urine anion gap calculator (optional)
Urine Na⁺
mEq/L
Urine K⁺
mEq/L
Urine Cl⁻
mEq/L

What is anion gap?

The anion gap is the difference between commonly measured serum cations and anions. Because electroneutrality must hold, any “gap” reflects unmeasured anions (albumin, phosphate, sulfate, organic acids). That is the clinical meaning of an anion gap blood test on a basic metabolic panel — it helps separate anion gap metabolic acidosis from non-anion gap metabolic acidosis.

Why calculate the serum anion gap?

When bicarbonate falls, knowing what causes elevated anion gap versus a normal-gap (hyperchloremic) process changes the work-up: lactate and ketones for high AG states, versus diarrhea or RTA for many NAGMA cases. This page mirrors the same core equations used by major bedside tools (serum AG ± potassium and albumin correction).

Measured vs unmeasured ions

Why a gap appears on routine labs.

Cations Na⁺ (+ K⁺ optional) (+ Ca²⁺, Mg²⁺ unmeasured) Anions Cl⁻ + HCO₃⁻ (+ albumin, acids…) AG ≈ measured cations − measured anions The leftover charge is the clinical anion gap.

Normal anion gap range

Modern ion-selective electrode bands (approx.).

Without K⁺ (mEq/L = mmol/L). With K⁺ many cite ~5–16. Confirm with your lab.

Anion gap formula

Daily serum anion gap calculation uses sodium, chloride and bicarbonate. This matches the standard approach in clinical calculators:

Anion gap formula Serum · without K⁺
AG = Na⁺ (Cl⁻ + HCO₃⁻) all in mEq/L or mmol/L

With potassium: AG = (Na⁺ + K⁺) − (Cl⁻ + HCO₃⁻)

How to calculate anion gap

  1. Pull Na⁺, Cl⁻ and HCO₃⁻ (or total CO₂) from the same chemistry panel.
  2. Decide anion gap with vs without potassium based on your protocol.
  3. Apply the anion gap formula above.
  4. If albumin is low, apply the anion gap albumin correction formula.
  5. Interpret against the normal anion gap range and the acid–base picture.

Worked example

Na 140 · Cl 104 · HCO₃ 12 · albumin 2.0 g/dL

  1. Serum AG: 140 − (104 + 12) = 24 mEq/L (high).
  2. Corrected AG: 24 + 2.5 × (4.0 − 2.0) = 29 mEq/L.
  3. Delta ratio: (24 − 12) ÷ (24 − 12) = 1.0 → consistent with relatively pure high-AG acidosis.
Result24mEq/L (corr. 29)

Corrected anion gap for albumin

Albumin is a major unmeasured anion. Hypoalbuminemia lowers the observed AG and can hide acidosis. The usual correction is:

Anion gap albumin correction formula ≈ +2.5 per 1 g/dL below 4.0
Corr AG = AG + 2.5 × (4.0 − Albuming/dL) Figge / Winters-style adjustment

High anion gap causes

What does high anion gap mean? Excess organic or inorganic anions. Classic teaching uses the anion gap MUDPILES mnemonic; many clinicians now prefer GOLDMARK.

MUDPILES (classic)

M Methanol U Uremia D Diabetic ketoacidosis (DKA) / ketones P Paraldehyde / propylene glycol I Iron / isoniazid / infection L Lactic acidosis E Ethylene glycol S Salicylates

Anion gap in DKA

In DKA, ketoacids raise the AG while HCO₃⁻ falls. As insulin therapy clears ketones, the AG falls — often before bicarbonate fully normalizes. Track serial AG alongside glucose, ketones, and volume status.

Low anion gap causes

What does low anion gap mean? Usually fewer negative charges from albumin. Other low anion gap causes: laboratory artifact, lithium, bromide/iodide interference, or cationic paraproteins. Is a low anion gap dangerous? Not always by itself — but unexplained lows deserve a cause, because they can hide a true high AG after albumin correction.

Non-anion gap metabolic acidosis

Acidosis with a normal AG is typically hyperchloremic: GI bicarbonate loss (diarrhea), renal tubular acidosis, saline resuscitation, or carbonic anhydrase inhibitors. Use the urine anion gap calculator section above to help separate GI from renal NH₄⁺ failure.

Delta gap / delta ratio calculator

When AG is high, the delta gap delta ratio calculator logic asks whether HCO₃⁻ fell as much as AG rose:

Delta ratio mixed acid–base clue
Δ / Δ (AG − 12) (24 − HCO₃⁻)
  • < 0.4 → predominant NAGMA
  • 0.4–0.8 → mixed HAGMA + NAGMA
  • ~0.8–2.0 → relatively pure HAGMA
  • > 2 → HAGMA plus metabolic alkalosis / prior high HCO₃⁻

Urine anion gap

Urine AG = (Nau + Ku) − Clu. A negative value supports appropriate ammonium excretion (often GI HCO₃⁻ loss); a positive value can suggest impaired renal acid excretion (RTA). It is a bedside clue — not a standalone diagnosis.

Anion gap vs osmolar gap

Anion gap vs osmolar gap: AG tracks charged unmeasured anions; osmolar gap tracks unmeasured osmoles (methanol, ethylene glycol, isopropyl alcohol, mannitol). Toxic alcohols may raise both, but a normal AG does not rule out early alcohol ingestion with a large osmolar gap.

FAQ

What is anion gap?

The anion gap is the difference between routinely measured cations and anions in serum. It estimates unmeasured anions and helps classify metabolic acidosis as high anion gap or non-anion gap (hyperchloremic).

What is the anion gap formula?

Without potassium: AG = Na⁺ − (Cl⁻ + HCO₃⁻). With potassium: AG = (Na⁺ + K⁺) − (Cl⁻ + HCO₃⁻). Values in mEq/L equal mmol/L for these monovalent ions.

What is a normal anion gap range?

With modern analyzers and potassium omitted, many labs cite about 3–11 mEq/L (mmol/L). Including potassium, a common band is about 5–16 mEq/L. Always use your laboratory’s reference interval.

What does high anion gap mean?

A high anion gap usually means excess unmeasured anions — classic high anion gap metabolic acidosis from lactate, ketoacids (including DKA), toxins, or uremia. Use clinical context and the MUDPILES or GOLDMARK mnemonics.

What does low anion gap mean?

A low anion gap is most often from hypoalbuminemia. Less common causes include lab error, lithium, bromide interference, or paraproteins. A low AG alone is not always dangerous but should be explained.

How do you correct anion gap for albumin?

Corrected AG = Observed AG + 2.5 × (4.0 − albumin in g/dL). Low albumin can mask an elevated anion gap, so albumin correction matters in critical illness.

What is the urine anion gap calculator used for?

Urine anion gap = (Na_u + K_u) − Cl_u. It helps distinguish GI bicarbonate loss (often negative UAG) from renal causes of non-anion gap metabolic acidosis such as RTA (often positive UAG).

What is delta gap / delta ratio?

Delta ratio ≈ (AG − 12) ÷ (24 − HCO₃⁻). It helps detect mixed acid-base disorders when high anion gap metabolic acidosis coexists with non-AG acidosis or metabolic alkalosis. It is a separate number from the serum AG itself.

Anion gap with vs without potassium — which should I use?

Most bedside tools omit potassium because K⁺ is small relative to Na⁺, Cl⁻, and HCO₃⁻. Including K raises the AG slightly and uses a wider normal band. Match the formula your lab or protocol expects.

Is anion gap the same as osmolar gap?

No. Anion gap reflects unmeasured charged anions. Osmolar gap reflects unmeasured osmotically active particles (e.g. alcohols). Both can rise together in toxic alcohol ingestions but they measure different things.

Dr. Emily Carter, PharmD, BCPS
Dr. Emily Carter, PharmD, BCPS
Board-Certified Clinical Pharmacist · Nephrology & Internal Medicine

Dr. Emily Carter, PharmD, BCPS is a board-certified clinical pharmacist specializing in nephrology and internal medicine. She has over 12 years of experience optimizing medication therapy for patients with chronic kidney disease, acute kidney injury, and critically ill adults. Her work focuses on evidence-based dosing, renal pharmacotherapy, and improving medication safety. She reviews all clinical content to ensure accuracy, clarity, and alignment with current medical guidelines.