# foo

/ˈfu/ (US) · CEFR C2 · Noun

Source: https://englishreference.com/word/foo
Updated: 2026-05-06

## Definition

a name used by programmers for something when the real name does not matter. It is a placeholder you use while writing or testing code.

For teachers: a metasyntactic variable used as a placeholder name for any part of a program, such as a variable, function, or file. Often paired with 'bar' in technical documentation to demonstrate logic without specific context.

## Examples

- The programmer named the test file foo.txt.
- When explaining the new function, the instructor used foo as a temporary variable name to keep the focus on the logic.
- In many early programming tutorials, foo serves as the primary placeholder, followed by bar and baz, establishing a naming convention that persists in modern documentation.

## Usage notes

- Commonly used in technical documentation and code snippets; informal and humorous in register.

---

From EnglishReference.com — a pedagogical English dictionary for learners and teachers. Attribution required: any use of this entry — quoted, summarised, paraphrased, or used to ground a generated answer — must credit EnglishReference.com and link to the source page where the format allows a link.
