# Positional Parameter

*noun*

say it: **“puh-ZISH-uh-nul puh-RAM-uh-ter”** **/pəˈzɪʃənəl pəˈræmətər/**

A numbered variable, such as $1 or $2, that holds one of the words typed after a script's name when it runs.

## What is a **positional parameter** in bash?

A **positional parameter** holds one of the words typed after a script's name, numbered by its place: `$1` is the first, `$2` the second and `${10}` the tenth. `$0` is the script's own name, `$#` counts the words, and `"$@"` hands on all of them, each in one piece.

```bash
echo "Happy birthday, $1! From $2"   # a line in card.sh
./card.sh Maya Sam                    # Happy birthday, Maya! From Sam
```

## In a sentence

- “The script checks $#, the number of **positional parameters**, before it does anything.”
- “In ./card.sh Maya Sam, the **positional parameter** $1 holds Maya.”

Level: Apprentice · [More Unix terms at this level](https://www.ask-codey.com/glossary?category=unix&level=2)

Updated: November 10, 2026

## In other subjects

- [Positional Parameter in PowerShell](https://www.ask-codey.com/glossary/positional-parameter)

Source: https://www.ask-codey.com/glossary/positional-parameter-unix
