Anion Gap Calculation
The anion gap measures the difference between blood cations and anions to identify metabolic acidosis. Enter your electrolyte values below for instant clinical interpretation.
Calculate Your Anion Gap
Enter your electrolyte values to get instant results with clinical interpretation and visual feedback.
Electrolyte Values
All values in mEq/L (mmol/L)
Results
Enter values and click Calculate to see your results
Anion Gap Formula & Calculation
The anion gap formula is straightforward. You need three lab values from a basic metabolic panel.
Standard Formula
This is the most widely used version. It subtracts the two major measured anions (chloride and bicarbonate) from the major measured cation (sodium). Most labs and textbooks default to this formula.
Adjusted Anion Gap
Some clinicians include potassium. Because potassium levels are small (3.5–5.0 mEq/L) and tightly regulated, this version rarely changes the clinical picture. The normal range shifts to 10–20 mEq/L when potassium is included.
Step-by-Step Calculation
Live Calculation Preview
This updates in real-time as you change the electrolyte values in the calculator above.
What is Anion Gap?
The anion gap is a calculated value from routine blood work that tells clinicians about the balance of charged particles in the blood.
Definition
The anion gap represents the difference between positively charged ions (cations) and negatively charged ions (anions) that are routinely measured in the blood. In a healthy person, this gap is made up of unmeasured anions — proteins like albumin, phosphate, sulfate, and organic acids.
The body always maintains electrical neutrality. Total cations must equal total anions. But standard lab panels only measure some of them. The anion gap fills in what the labs don't directly report.
Clinical Importance
Doctors order the anion gap when they suspect acid-base problems. It helps answer a specific question: is there an excess of unmeasured acids in the blood? A high anion gap points to conditions like diabetic ketoacidosis, lactic acidosis, or toxic ingestions. A normal anion gap with acidosis suggests chloride-related problems like diarrhea or renal tubular acidosis.
Anion Gap Normal Range
Normal values depend on the formula used and can vary slightly between laboratories.
Normal Values
The standard anion gap (without potassium) normally falls between 8 and 12 mEq/L. When potassium is included in the corrected formula, the normal range is 10 to 20 mEq/L.
These numbers assume a normal serum albumin of about 4 g/dL. Each 1 g/dL drop in albumin lowers the anion gap by roughly 2.5 mEq/L. So a patient with an albumin of 2 g/dL might have a "normal" AG of only 3–7 mEq/L — which could mask a true elevation.
Variations
Different labs may report slightly different reference ranges based on their analyzers and local population data. Some institutions quote 4–12 mEq/L, others 8–16 mEq/L. Always check your lab's specific reference range.
Ion-selective electrode technology in modern analyzers tends to produce slightly different values than older flame photometry methods. When comparing results over time, make sure the same methodology was used.
| Electrolyte | Symbol | Normal Range | Unit | Role in AG |
|---|---|---|---|---|
| Sodium | Na⁺ | 136 – 145 | mEq/L | Primary measured cation |
| Potassium | K⁺ | 3.5 – 5.0 | mEq/L | Included in corrected formula |
| Chloride | Cl⁻ | 98 – 106 | mEq/L | Primary measured anion |
| Bicarbonate | HCO₃⁻ | 22 – 28 | mEq/L | Acid-base buffer anion |
| Anion Gap (Standard) | AG | 8 – 12 | mEq/L | Na⁺ − (Cl⁻ + HCO₃⁻) |
| Anion Gap (Corrected) | AGc | 10 – 20 | mEq/L | (Na⁺ + K⁺) − (Cl⁻ + HCO₃⁻) |
Where Does Your AG Fall?
This gauge shows your current anion gap value from the calculator. Change the electrolyte values above to see the needle move.
Anion Gap Interpretation
What different anion gap values mean and what conditions to consider.
High Anion Gap Causes
- Diabetic ketoacidosis (DKA)
- Lactic acidosis (sepsis, shock)
- Renal failure (uremia)
- Toxic alcohol ingestion
- Salicylate overdose
- Starvation ketoacidosis
Normal Anion Gap (Hyperchloremic)
- Diarrhea (GI bicarbonate loss)
- Renal tubular acidosis (RTA)
- Normal saline overload
- Carbonic anhydrase inhibitors
- Ureteral diversions
- Addison's disease
Low Anion Gap Causes
- Hypoalbuminemia (most common)
- Multiple myeloma (IgG)
- Lithium toxicity
- Bromide ingestion (lab artifact)
- Hypercalcemia
- Hypermagnesemia
High Anion Gap Metabolic Acidosis Causes
When the anion gap is elevated, clinicians use mnemonics to recall the differential diagnosis.
MUDPILES Mnemonic
GOLDMARK Mnemonic
An alternative to MUDPILES that some clinicians prefer:
Clinical Examples
A 45-year-old with diabetes presents with nausea and rapid breathing. Labs show Na⁺ 138, Cl⁻ 100, HCO₃⁻ 10. The anion gap is 138 − (100 + 10) = 28 mEq/L — significantly elevated. Combined with high blood glucose and positive urine ketones, this points to diabetic ketoacidosis.
A 70-year-old with sepsis arrives in shock. Labs show Na⁺ 140, Cl⁻ 102, HCO₃⁻ 14. AG = 140 − (102 + 14) = 24 mEq/L. Serum lactate is 8 mmol/L. The elevated anion gap is driven by lactic acidosis from poor tissue perfusion.
Try a Clinical Scenario
Click a scenario to auto-fill the calculator with real-world lab values and see how the anion gap changes.
Anion Gap Clinical Applications
When and why clinicians order an anion gap calculation.
Indications
The anion gap should be calculated whenever you have a basic metabolic panel (BMP) or comprehensive metabolic panel (CMP) and suspect an acid-base disorder. Common scenarios include:
- Metabolic acidosis workup — The anion gap is the first step in narrowing the cause of a low bicarbonate.
- Altered mental status — Toxic ingestions (methanol, ethylene glycol) cause a high AG and require urgent treatment.
- Diabetic emergencies — Monitoring the AG during DKA treatment tracks whether ketoacid production is slowing.
- Sepsis and shock — Lactic acidosis from poor perfusion shows up as a rising anion gap.
- Renal failure monitoring — As kidney function declines, unmeasured anions accumulate and the AG rises.
- ICU monitoring — Serial anion gap measurements help track treatment response in critically ill patients.
Diagnostic Decision Tree
This flowchart highlights the active path based on your current lab values from the calculator.
How Anion Gap Works
The physiology behind electrolyte balance and why the anion gap changes in disease.
Anion Gap and Electrolyte Balance
Blood must stay electrically neutral. Every positive charge has a matching negative charge. Standard lab panels measure sodium and potassium on the cation side, and chloride and bicarbonate on the anion side. But they miss many other charged particles — albumin, phosphate, sulfate, and organic acids on the anion side, and calcium, magnesium, and gamma globulins on the cation side.
Because unmeasured anions normally outweigh unmeasured cations, the measured cations always appear to exceed the measured anions. That difference is the anion gap.
Pathophysiology of Anion Gap Disorders
When the body produces excess acid (like lactate or ketoacids), these acids release hydrogen ions. The hydrogen ions consume bicarbonate as a buffer, lowering the HCO₃⁻ level. But the conjugate base (lactate, ketoanion) remains — it becomes an unmeasured anion. The result: bicarbonate drops, unmeasured anions rise, and the anion gap increases.
In non-anion gap acidosis, the story is different. Bicarbonate is lost directly (through the gut or kidneys), and chloride rises to maintain electrical neutrality. The anion gap stays normal because no new unmeasured anions appear.
Interactive Ion Balance
Watch how the unmeasured anion column (the anion gap) grows or shrinks as you change the electrolyte values in the calculator.
Frequently Asked Questions
Answers to common clinical and technical questions about the anion gap.