In mathematics, a **Cantor space**, named for Georg Cantor, is a topological abstraction of the classical Cantor set: a topological space is a **Cantor space** if it is homeomorphic to the Cantor set. In set theory, the topological space 2^{ω} is called "the" Cantor space.

The Cantor set itself is a Cantor space. But the canonical example of a Cantor space is the countably infinite topological product of the discrete 2-point space {0, 1}. This is usually written as or 2^{ω} (where 2 denotes the 2-element set {0,1} with the discrete topology). A point in 2^{ω} is an infinite binary sequence, that is a sequence that assumes only the values 0 or 1. Given such a sequence *a*_{0}, *a*_{1}, *a*_{2},..., one can map it to the real number

This mapping gives a homeomorphism from 2^{ω} onto the Cantor set, demonstrating that 2^{ω} is indeed a Cantor space.

Cantor spaces occur abundantly in real analysis. For example, they exist as subspaces in every perfect, complete metric space. (To see this, note that in such a space, any non-empty perfect set contains two disjoint non-empty perfect subsets of arbitrarily small diameter, and so one can imitate the construction of the usual Cantor set.) Also, every uncountable, separable, completely metrizable space contains Cantor spaces as subspaces. This includes most of the common spaces in real analysis.

A topological characterization of Cantor spaces is given by Brouwer's theorem:^{[1]}

Any two non-empty compact Hausdorff spaces without isolated points and having countable bases consisting of clopen sets are homeomorphic to each other.

The topological property of having a base consisting of clopen sets is sometimes known as "zero-dimensionality". Brouwer's theorem can be restated as:

A topological space is a Cantor space if and only if it is non-empty, perfect, compact, totally disconnected, and metrizable.

This theorem is also equivalent (via Stone's representation theorem for Boolean algebras) to the fact that any two countable atomless Boolean algebras are isomorphic.

As can be expected from Brouwer's theorem, Cantor spaces appear in several forms. But many properties of Cantor spaces can be established using 2^{ω}, because its construction as a product makes it amenable to analysis.

Cantor spaces have the following properties:

- The cardinality of any Cantor space is , that is, the cardinality of the continuum.
- The product of two (or even any finite or countable number of) Cantor spaces is a Cantor space. Along with the Cantor function, this fact can be used to construct space-filling curves.
- A (non-empty) Hausdorff topological space is compact metrizable if and only if it is a continuous image of a Cantor space.
^{[2]}^{[3]}^{[4]}

Let *C*(*X*) denote the space of all real-valued, bounded continuous functions on a topological space *X*. Let *K* denote a compact metric space, and Δ denote the Cantor set. Then the Cantor set has the following property:

In general, this isometry is not unique, and thus is not properly a universal property in the categorical sense.