# NaN

*noun*

say it: **“NAN”** **/næn/**

Not a Number: the value JavaScript gives when math on something that isn't a number fails.

## What is **NaN** in JavaScript?

**NaN** — A special Number value meaning the result is not a valid number.

```javascript
const result = Number("tea");
const invalid = Number.isNaN(result);
```

## In a sentence

- “Number("abc") gave **NaN**, so the total showed NaN too.”

Level: Novice · [More JavaScript terms at this level](https://www.ask-codey.com/glossary?category=javascript&level=1)

Updated: November 9, 2026

## In other subjects

- [NaN in Python](https://www.ask-codey.com/glossary/nan-python)

Source: https://www.ask-codey.com/glossary/nan
