The Normalized Difference Water Index (NDWI) highlights open water in satellite imagery. Like NDVI, it compares two bands of light and gives a value from −1 to 1. Water scores high; land scores low. It's used to map lakes, rivers, reservoirs and floods, and to track how shorelines and wetlands change.

How NDWI works

Water reflects a little green light but absorbs almost all near-infrared (NIR). Vegetation and soil do the opposite: they reflect far more NIR than green. The index, published by McFeeters in 1996, contrasts the two:

NDWI = (Green − NIR) ÷ (Green + NIR)

Positive values usually mean water; zero and below usually mean land. A threshold of 0 is a common starting point, tuned for each scene.

Careful: there are two NDWIs

Also in 1996, Gao published a different index with the same name: (NIR − SWIR) ÷ (NIR + SWIR). It measures the water content of vegetation, not open water, and is now usually called the Normalized Difference Moisture Index (NDMI). Software and papers still mix the two up. Before using an "NDWI" layer, check which bands went into it.

The two NDWIs
AspectMcFeeters NDWIGao NDWI (NDMI)
BandsGreen and NIRNIR and shortwave infrared (SWIR)
MeasuresOpen waterMoisture in leaves and canopy
High values meanWaterWell-watered vegetation
Typical usesLakes, floods, shorelinesDrought stress, fire risk, irrigation

MNDWI: better water maps near cities

Built-up surfaces can also reflect more green than NIR, so NDWI sometimes mistakes roofs and roads for water. In 2006, Xu proposed the Modified NDWI (MNDWI), which swaps NIR for shortwave infrared:

MNDWI = (Green − SWIR1) ÷ (Green + SWIR1)

Built-up land reflects strongly in SWIR, so its MNDWI drops further below zero, while water stays high.

NDWI and MNDWI for typical surfacesBars compare NDWI and MNDWI. Water is positive on both, 0.60 and 0.78. Vegetation, bare soil and built-up land are negative; MNDWI pushes built-up land further below zero, minus 0.30 instead of minus 0.14.NDWI (green, NIR)MNDWI (green, SWIR)WaterWater: +0.60+0.60Water: +0.78+0.78VegetationVegetation: -0.70-0.70Vegetation: -0.47-0.47Bare soilBare soil: -0.25-0.25Bare soil: -0.36-0.36Built-upBuilt-up: -0.14-0.14Built-up: -0.30-0.30-1-0.500.51Above 0: likely water →
Values use typical surface reflectance, the share of light reflected from 0 to 1. They're illustrative; real values vary with sensor, season and site. Hover a bar to see its value.
Worked values
SurfaceGreenNIRSWIR1NDWIMNDWI
Water0.080.020.01+0.60+0.78
Vegetation0.080.450.22−0.70−0.47
Bare soil0.150.250.32−0.25−0.36
Built-up0.150.200.28−0.14−0.30

For water: NDWI = (0.08 − 0.02) ÷ (0.08 + 0.02) = 0.60.

Which bands to use

Bands for NDWI and MNDWI
SatelliteGreenNIRSWIR1Resolution
Sentinel-2B3B8B1110 m (SWIR 20 m)
Landsat 8 and 9B3B5B630 m

MNDWI uses SWIR, which Sentinel-2 records at 20 m rather than 10 m, so MNDWI maps are slightly coarser.

Uses

  • Flood mapping: comparing water extent before and after a storm.
  • Reservoirs and drought: tracking how much a lake has shrunk.
  • Shorelines and wetlands: measuring erosion, accretion and seasonal flooding.
  • Masking: removing water before calculating other indices, since water distorts burn and moisture indices.

Limits

  • Clouds and cloud shadows can look like water. Radar satellites such as Sentinel-1 see through clouds and are often used for floods.
  • Muddy or shallow water reflects more NIR and can score near zero.
  • Shadows from mountains and tall buildings are dark in all bands and can be mistaken for water.
  • Thresholds vary. Zero is a guide; the best cut-off differs between scenes.

Frequently asked questions

Is NDWI the same as NDMI?

Gao's NDWI is the same formula as NDMI. McFeeters' NDWI, the water-body index, is different. Check the bands.

Can NDWI map floods under clouds?

No. Optical satellites can't see through cloud. Radar such as Sentinel-1 is used for that.

What threshold should I use?

Start at 0 and adjust by checking against known water in the same image.

Need water or flood maps?

We'll map water extent and how it changes.

Floods, reservoirs, shorelines or wetlands: tell us the place and the dates.