NDCG (pronounced “EN-DEE-CEE-GEE”) measures how good a result ranking is, given a graded relevance label per item (e.g., 0 = irrelevant, 1 = somewhat, 2 = exact match). It computes Discounted Cumulative Gain by summing relevance with a logarithmic position discount, then normalizes against the perfect ordering so scores are comparable across queries.
For ecommerce search teams, NDCG@10 (truncated to the top 10 results) is the standard offline metric. It catches both relevance failures (a great product on page 4) and ranking failures (a mediocre product at #1). Pair it with a click-or-conversion-based online metric to validate that NDCG improvements translate to revenue.
Caveat: NDCG depends on the quality of your relevance labels. Crowdsourced or LLM-generated labels are often noisy. Many teams switch to engagement-derived metrics (reciprocal rank of clicks, position-bias-corrected CTR) once they have enough live traffic.