# Hoisting

*noun*

say it: **“HOYST-ing”** **/ˈhɔɪstɪŋ/**

JavaScript noting every declaration in a scope before it runs that scope, which is why a function can be called above the line that defines it.

## What is **Hoisting** in JavaScript?

**Hoisting** — The effect of declarations being registered before execution reaches their source line.

```javascript
showStatus();

function showStatus() {
    return "Ready";
}
```

## In a sentence

- “Thanks to **hoisting**, I could call greetCustomer() on line 1 even though the function is written at the bottom of the file.”

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

Updated: November 9, 2026

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