An ordered pair (a, b) is a pair of objects where order matters: (a, b) ≠ (b, a) unless a = b. Two ordered pairs are equal if and only if their first components agree and their second components agree: (a, b) = (c, d) if and only if a = c and b = d.

In set theory, ordered pairs are constructed from sets using the Kuratowski definition: (a, b) = {{a}, {a, b}}. This encoding ensures the order condition holds using only the axioms of set theory. The Cartesian product A × B is the set of all ordered pairs (a, b) with a ∈ A and b ∈ B.

Ordered pairs are the building blocks of relations and functions: a relation on A × B is a subset of A × B, and a function f: A → B is a relation where each a appears in exactly one pair. In a category, the Cartesian product generalizes to the categorical product, and ordered pairs generalize to product projections. Ordered n-tuples (a₁, a₂, …, aₙ) extend the idea to any finite length, encoding finite sequences.