connected space



A space is connected if it can't be split up into two independent parts. On this page we focus on connectedness for topological spaces.

Every topological space can be decomposed into disjoint maximal connected subspaces, called its connected components. The underlying set of a topological space is the disjoint union of the underlying sets of its connected components, but the space itself is not necessarily the coproduct of its connected components in the category of spaces.

One often studies topological ideas first for connected spaces and then generalises to general spaces. This is especially true if one is studying such nice topological spaces that every space is a coproduct of connected components (such as for example locally connected spaces; see below).


Speaking category-theoretically a topological space XX is connected if the representable functor

hom(X,):TopSet hom(X, -): Top \to Set

preserves coproducts. It's actually enough to require that it preserves binary coproducts (a detailed proof in a more general setting is given at connected object); in that case, notice that we always have a map

hom(X,Y)+hom(X,Z)hom(X,Y+Z), hom(X,Y) + hom(X,Z) \to hom(X,Y + Z) ,

so XX is connected if this is always a bijection. This definition generalises to the notion of connected object in an extensive category.

Here are some equivalent ways to say that XX is connected in more elementary terms:

  • Whenever XY+ZX \cong Y + Z, where the right side is the coproduct of spaces Y,ZY, Z (so that Y,ZY, Z are identified with disjoint open subspaces of XX), then exactly one of Y,ZY, Z is inhabited (so the other is empty, making the inhabited one homeomorphic to XX).
  • If KXK \subseteq X is clopen (both closed and open), then K=XK = X if and only if KK is inhabited.

Many authors allow the empty space to be connected. You can get this concept from the elementary definitions above by changing ‘exactly one’ to ‘at most one’ and changing ‘if and only if’ to ‘if’. Categorially, this version of connectedness requires only that the maps

hom(X,Y)+hom(X,Z)hom(X,Y+Z) hom(X,Y) + hom(X,Z) \to hom(X,Y + Z)

be surjections. However, many results come out more cleanly by disqualifying the empty space (much as one disqualifies 11 when one defines the notion of prime number). See also the discussion at empty space and too simple to be simple.

The elementary definitions above have been carefully phrased to be correct in constructive mathematics. One may also see classically equivalent forms that are constructively weaker.

Basic results


The image of a connected space XX under a continuous map f:XYf: X \to Y is connected.


Wide pushouts of connected spaces are connected. (This would of course be false if the empty space were considered to be connected.) This follows from the hom-functor definition of connectedness, plus the fact that coproducts in SetSet commute with wide pullbacks. More memorably: connected colimits of connected spaces are connected.


An arbitrary product of connected spaces is connected. (This relies on some special features of TopTop. Discussion of this point can be found at connected object.)


The interval [0,1][0, 1], as a subspace of \mathbb{R}, is connected. (This is the topological underpinning of the intermediate value theorem.)


If SXS \subseteq X is a connected subspace and STS¯S \subseteq T \subseteq \overline{S} (i.e. if TT is between SS and its closure), then TT is connected.

Exotic examples

The basic results above give a plethora of ways to construct connected spaces. More exotic examples are sometimes useful, especially for constructing counterexamples.


The following, due to Bing, is a countable connected Hausdorff space. Let Q={(x,y)×:y0}Q = \{(x, y) \in \mathbb{Q} \times \mathbb{Q}: y \geq 0\}, topologized by defining a basis of neighborhoods N ϵ,a,bN_{\epsilon, a, b} for each point (a,b)Q(a, b) \in Q and ϵ>0\epsilon \gt 0:

N a,b{(a,b)}{(s,0)Q:a+b/θs<ϵ}{(s,0)Q:ab/θs<ϵ}N_{a, b} \coloneqq \{(a, b)\} \cup \{(s, 0) \in Q: {|a + b/\theta - s|} \lt \epsilon\} \cup \{(s, 0) \in Q: {|a - b/\theta - s|} \lt \epsilon\}

where θ<0\theta \lt 0 is some chosen fixed irrational number. It is easy to see this space is Hausdorff (using the fact that θ\theta is irrational). However, the closure of N ϵ,a,bN_{\epsilon, a, b} consists of points (x,y)(x, y) of Q×QQ \times Q with either (xa)ϵ(yb)/θ(xa)+ϵ(x-a) - \epsilon \leq (y-b)/\theta \leq (x-a) + \epsilon or (xa)ϵ(yb)/θ(xa)+ϵ(x-a) - \epsilon \leq -(y-b)/\theta \leq (x-a) + \epsilon, in other words, the union of two infinitely long strips of width 2ϵ2\epsilon and slopes θ\theta, θ-\theta. Clearly any two such closures intersect, and therefore the space is connected.


This example is due to Golomb. Topologize the set of natural numbers \mathbb{N} by taking a basis to consist of sets A a,b{ak+bk=1,2,}A_{a,b} \coloneqq \{a k + b | k = 1,2, \ldots\}, where a,ba, b \in \mathbb{N} are relatively prime. The space is Hausdorff, but the intersection of the closures of two non-empty open sets is never empty, so this space is connected.

Connected components

Every topological space XX admits an equivalence relation \sim where xyx \sim y means that xx and yy belong to some subspace which is connected. The equivalence class Conn(x)Conn(x) of an element xx is thus the union of all connected subspaces containing xx; it follows readily from Result 2 that Conn(x)Conn(x) is itself connected. It is called the connected component of xx. It is closed, by Result 5. A space is connected if and only if it has exactly one connected component (or at most one, if you allow the empty space to be connected).

There is another equivalence relation q\sim_q where x qyx \sim_q y if f(x)=f(y)f(x) = f(y) for every continuous f:XDf: X \to D mapping to a discrete space DD. The equivalence class of xx may be alternatively described as the intersection of all clopens that contain xx. This is called the quasi-component of xx, denoted here as QConn(x)QConn(x). It is easy to prove that

Conn(x)QConn(x)Conn(x) \subseteq QConn(x)

and that equality holds if XX is compact Hausdorff or is locally connected (see below), but also in other circumstances (such as the space of rational numbers as a topological subspace of the real line).


For an example where Conn(x)QConn(x)Conn(x) \neq QConn(x), take XX to be the following subspace of [0,1]×[0,1][0, 1] \times [0, 1]:

X={(0,0),(0,1)} n1{1/n}×[0,1]X = \{(0, 0), (0, 1)\} \cup \bigcup_{n \geq 1} \{1/n\} \times [0, 1]

In this example, Conn((0,1))={(0,1)}Conn((0, 1)) = \{(0, 1)\}, but QConn((0,1))={(0,0),(0,1)}QConn((0, 1)) = \{(0, 0), (0, 1)\}.

Locally connected spaces

An entry point is given in the following remark/warning:


It is not generally true that a space is the coproduct (in TopTop) of its connected components, nor of its quasi-components. For example, the connected components in Cantor space 2 2^{\mathbb{N}} (with its topology as a product of 2-point discrete spaces) are just the singletons, but the coproduct of the singleton subspaces carries the discrete topology; another example with this feature is the set of rational numbers with its absolute-value topology (the one induced as a topological subspace of the real line).


A space XX is locally connected if every open set, as a topological space, is the coproduct (in TopTop) of its connected components. Equivalently, a space is locally connected if every point has a neighborhood basis of connected open sets.

In a locally connected space, every connected component SS is clopen; in particular, connected components and quasi-components coincide. We warn that connected spaces need not be locally connected; for example, the topologist’s sine curve of Example 4 is connected but not locally connected.

Examples of locally connected spaces include topological manifolds.

Let i:LocConnTopi \colon LocConn \hookrightarrow Top be the full inclusion of locally connected spaces. The following result is straightforward but useful.


LocConnLocConn is a coreflective subcategory of TopTop, i.e., the inclusion ii has a right adjoint RR. For XX a given space, R(X)R(X) has the same underlying set as XX, topologized by letting connected components of open subspaces of XX generate a topology.

Being a coreflective category of a complete and cocomplete category, the category LocConnLocConn is also complete and cocomplete. Of course, limits and particularly infinite products in LocConnLocConn are not calculated as they are in TopTop; rather one takes the limit in TopTop and then retopologizes it according to Theorem 1. (For finite products of locally connected spaces, we can just take the product in TopTop – the result will be again locally connected.)

Let Γ:LocConnSet\Gamma \colon LocConn \to Set be the underlying set functor, and let ,Δ:SetLocConn\nabla, \Delta \colon Set \to LocConn be the functors which assign to a set the same set equipped with the codiscrete and discrete topologies, respectively. Let Π 0:LocConnSet\Pi_0 \colon LocConn \to Set be the functor which assigns to a locally connected space the set of its connected components.


There is a string of adjoints

Π 0ΔΓ:SetLocConn\Pi_0 \dashv \Delta \dashv \Gamma \dashv \nabla \colon Set \to LocConn

and moreover, the functor Π 0\Pi_0 preserves finite products.

The proof is largely straightforward; we point out that the continuity of the unit XΔΠ 0XX \to \Delta \Pi_0 X is immediate from a locally connected space’s being the coproduct of its connected components. As for Π 0\Pi_0 preserving finite products, write locally connected spaces XX, YY as coproducts of connected spaces

X= iC i;Y= jD j;X = \sum_i C_i; \qquad Y = \sum_j D_j;

then their product in LocConnLocConn coincides with their product in TopTop, and is

X×Y i,jC i×D jX \times Y \cong \sum_{i, j} C_i \times D_j

where each summand C i×D jC_i \times D_j is connected by Result 3. From this it is immediate that Π 0\Pi_0 preserves finite products.

The category of sheaves on a locally connected space is a locally connected topos. For related discussions, see also cohesive topos.



A space XX is totally disconnected if its connected components are precisely the singletons of XX.

In other words, a space is totally disconnected if its coreflection into LocConnLocConn is discrete. Such spaces recur in the study of Stone spaces.


An important variation on the theme of connectedness is path-connectedness. If XX is a space, define the path component [x][x] to be the subspace of all yXy \in X for which there exists a continuous map h:[0,1]Xh: [0, 1] \to X where h(0)=xh(0) = x, h(1)=yh(1) = y.

The set π 0(X)\pi_0(X) of path components (the 0th “homotopy group”) is thus the coequalizer in

hom([0,1],X)ev 1ev 0hom(1,X)π 0(X). \hom([0, 1], X) \stackrel{\overset{ev_0}{\to}}{\underset{ev_1}{\to}} \hom(1, X) \to \pi_0(X) .

Observe that this is a reflexive coequalizer, as witnessed by the mutual right inverse hom(!,X):hom(1,X)hom([0,1],X)\hom(!, X): \hom(1, X) \to \hom([0, 1], X).

(We can even topologize π 0(X)\pi_0(X) by taking the coequalizer in TopTop of

X [0,1]ev 1ev 0X,X^{[0, 1]} \stackrel{\overset{ev_0}{\to}}{\underset{ev_1}{\to}} X,

taking advantage of the fact that the locally compact Hausdorff space [0,1][0, 1] is exponentiable. The resulting quotient space will be discrete if XX is locally path-connected.)

We say XX is path-connected if it has exactly one path component.

It follows easily from the basic results above that each path component [x][x] is connected. However, it need not be closed (and therefore need not be the connected component of xx); see the following example. The path components and connected components do coincide if XX is locally path-connected.


The topologist’s sine curve

{(x,y) 2:(0<x1y=sin(1/x))(0=x1y1)} \{ (x, y) \in \mathbb{R}^2 \;:\; (0 \lt x \leq 1 \;\wedge\; y = sin(1/x)) \;\vee\; (0 = x \;\wedge\; -1 \leq y \leq 1) \}

provides a classic example where the path component of a point need not be closed. (Specifically, consider a point on the locus of y=sin(1/x)y = \sin(1/x).)

The basic categorical Results 1, 2, and 3 above carry over upon replacing “connected” by “path-connected”. (As of course does 4, trivially.)

As a contrast to a path-connected space, a totally path-disconnected space is a space such that its set of path components is equal to the underlying set of the space. Equivalently, that there are no non-constant paths. This by far does not mean that the space is discrete!

Path-components functor

As above, let π 0:TopSet\pi_0 \colon Top \to Set be the functor which assigns to each space XX its set of path components π 0(X)\pi_0(X).


The functor π 0:TopSet\pi_0 \colon Top \to Set preserves arbitrary products.


Let X iX_i be a family of spaces; we must show that the comparison map

π 0( iX i) iπ 0(X i)\pi_0(\prod_i X_i) \to \prod_i \pi_0(X_i)

is invertible. Injectivity: suppose (x i),(y i) iX i(x_i), (y_i) \in \prod_i X_i are tuples that map to the same tuple of path-components (c i)(c_i); we must show that (x i)(x_i) and (y i)(y_i) belong to the same path component. For each ii, both x ix_i and y iy_i belong to c ic_i, so we may choose a path α i:IX i\alpha_i: I \to X_i connecting x ix_i to y iy_i. Then α i:I iX i\langle \alpha_i \rangle \colon I \to \prod_i X_i connects (x i)(x_i) to (y i)(y_i). (Note this uses the axiom of choice.) Surjectivity: for any tuple (c i) iπ 0(X i)(c_i) \in \prod_i \pi_0(X_i), the component c ic_i is nonempty for each ii, so we may choose an element x ix_i therein. Then (x i)(x_i) maps to (c i)(c_i). Again this uses the axiom of choice.

An elegant proof of the previous proposition but for preservation of finite products is as follows: both hom(I,)\hom(I, -) and hom(1,)\hom(1, -) preserve products, and a reflexive coequalizer of product-preserving functors CSetC \to Set, being a sifted colimit, is also product-preserving.


The functor π 0:TopSet\pi_0 \colon Top \to Set preserves arbitrary coproducts.


The functor hom(I,):TopSet\hom(I, -) \colon Top \to Set preserves coproducts since II is connected, and similarly for hom(1,)\hom(1, -). The coequalizer of a pair of natural transformations between coproduct-preserving functors is also a coproduct-preserving functor.


Examples of countable connected Hausdorff spaces were give in

  • R.H. Bing, A connected countable Hausdorff space, Proc. Amer. Math. Soc. 4 (1953), 474.
  • Solomon W. Golomb, A Connected Topology for the Integers, Amer. Math. Monthly, Vol. 66 No. 8 (Oct. 1959), 663-665.

Revised on July 4, 2013 06:19:58 by Toby Bartels (