# Urine Anion Gap Calculator

URL: https://speedycalculator.com/calculators/health/urine-anion-gap/
Last updated: 2026-10-30

> The urine anion gap calculator estimates urinary ammonium excretion from urine sodium, potassium and chloride to separate renal from gastrointestinal causes of a normal anion gap (hyperchloraemic) metabolic acidosis.

## Inputs

- Urine sodium (mEq/L)
- Urine potassium (mEq/L)
- Urine chloride (mEq/L)

## Results

- Urine anion gap
- Interpretation in normal anion gap acidosis

## Formula

```
Urine anion gap = urine Na⁺ + urine K⁺ − urine Cl⁻
Negative: kidney excreting acid (diarrhoea likely) · Positive: impaired acid excretion (renal tubular acidosis)
```

## Explanation

When the kidneys respond normally to acidosis they excrete lots of ammonium chloride, making the urine anion gap negative. A positive gap suggests renal tubular acidosis. The test is unreliable with high urine ketones, very low urine sodium or volume depletion.

### How to use the Urine Anion Gap Calculator

- **Urine sodium**
- **Urine potassium**
- **Urine chloride**

Results update as you type, and every field accepts the units shown in its menu.

### How it works

Enter urine sodium, potassium and chloride from a spot urine sample.

### Inputs explained

FieldWhat to enterUrine sodiumIn mEq/LUrine potassiumIn mEq/LUrine chlorideIn mEq/L

### Example values

How the main result changes when **Urine sodium** changes and everything else stays at the example values above:

Urine sodium (mEq/L)Urine anion gap (mEq/L)20-4030-3040-2050-106008020
*Health note: this calculator is for education and screening only and is not a diagnosis or treatment advice. Discuss your results with a qualified clinician.*

## Worked example

Inputs — Urine sodium: 40 mEq/L; Urine potassium: 30 mEq/L; Urine chloride: 90 mEq/L.

Results — **Urine anion gap = -20 mEq/L**; Interpretation in normal anion gap acidosis = Negative – gastrointestinal bicarbonate loss likely (e.g. diarrhoea).

## Key terms

- **RTA**: Renal tubular acidosis.

## FAQ

**What does a negative urine anion gap mean?**
The kidney is excreting ammonium appropriately – think diarrhoea.

**When is the test unreliable?**
With ketones, very low urine sodium (< 25 mEq/L) or polyuria.

**What is the alternative?**
The urine osmolal gap.


## Sources

- [Batlle DC et al. The use of the urinary anion gap in the diagnosis of hyperchloremic metabolic acidosis. N Engl J Med, 1988](https://pubmed.ncbi.nlm.nih.gov/3340118/)
