The question is in the title, I'll rephrase it slightly here.

I am wondering how to prove that a topological space $X$ is connected if and only if it has exactly two clopen (closed and open) subsets.

Apart from writing down the definitions of connected, open and closed I really have no idea how to prove this. Any suggestions?

  • 5
    $\begingroup$ If a topological space can be written as the disjoint union of two open components, what can be said about the complements of those components? $\endgroup$
    – Adam Saltz
    Apr 14, 2013 at 16:09
  • 1
    $\begingroup$ What if your space $X$ is the empty space? It only has one clopen subset: itself. $\endgroup$
    – kahen
    Apr 14, 2013 at 16:12
  • 3
    $\begingroup$ @kahen: Many texts specify that a topological space is a non-empty set equipped with a topology. $\endgroup$ Apr 14, 2013 at 16:14

3 Answers 3


$(\Leftarrow)$: Considering the contrapositive... Let $X$ be a disconnected topological space. That is to say, there exist non-empty open subsets $U$, $V \subset X$ such that $U \cap V = \emptyset $ and $U \cup V=X$. Here $U$ and $V$ are clopen subsets of $X$ since $U^c=V$ and $V^c=U$.

$(\Rightarrow)$: Suppose now that $X$ is connected. Then there exist two clopen subsets of $X$, namely $\emptyset$ and $X$ itself. Here, recall that $\emptyset$ and $X$ are clopen by definition.

  • 3
    $\begingroup$ thanks! But I guess the argument for the $\Rightarrow$ isn't entirely complete, because we also have to consider the possiblity that there are more than or less than 2 clopen subsets of $X$, shouldn't we? $\endgroup$
    – Max Muller
    Apr 14, 2013 at 16:26
  • 2
    $\begingroup$ @Max: So long as $X$ is non-empty, there cannot be fewer than $2$ clopen subsets of $X$. $X$ and $\emptyset$ are necessarily clopen, regardless of the topology on $X$. A set is clopen if and only if its complement is clopen, so if there were any other clopen sets, then $X$ would have a separation, impossible since $X$ is connected. $\endgroup$ Apr 14, 2013 at 16:30
  • 1
    $\begingroup$ Metin: For $(\Leftarrow)$, you need to specify that $U,V$ are non-empty. $\endgroup$ Apr 14, 2013 at 16:31
  • 1
    $\begingroup$ Sure, forgot to mention. Thanks... $\endgroup$
    – Metin Y.
    Apr 14, 2013 at 16:36
  • $\begingroup$ Sir as $X=U\cup V$ and $U\cap V$ is empty. Hence $U\subset V^{c}$ and $V\subset U^{c}$. How $U=V^{c}$ ? $\endgroup$ Sep 9, 2019 at 5:07

Always there are at least two clopen subsets, namely $\emptyset,X$. If there is another one, let's say $U$, then $U\neq\emptyset$ and $U\neq X$.
Consider the subsets $U$ and $U^c$ to show that $X$ is disconnected.


We would like to prove that $X$ is connected iff the only sets in $X$ that are clopen are $\varnothing$ and $X$.

$\Rightarrow$: (by contrapositive). Assume that there is a clopen subset $A$ of $X$ such that $A\neq \varnothing$ and $A\neq X$. Then the pair $(A, A^c)$ forms a separation of $X$. Thus, $X$ is not connected.

$\Leftarrow$: (by contrapositive). Suppose $X$ is not connected. Then there exist two nonempty disjoint open sets $A$ and $B$ such that $X=A\cup B$. This implies that $A$ and $B$ are complement to each other. Thus, $A=B^c$. Hence, $A$ is closed. Therefore, $A$ is a clopen subset of $X$ satisfying $A\neq \varnothing$ and $A\neq X$.

  • $\begingroup$ Sir, How that implise $A$ and $B$ are complement of each other. $\endgroup$ Sep 9, 2019 at 4:51
  • $\begingroup$ Sir as $X=A\cup B$ and $A\cap B$ is empty. Hence $A\subset B^{c}$ and $B\subset A^{c}$. How $A=B^{c}$ ? $\endgroup$ Sep 9, 2019 at 5:05
  • 1
    $\begingroup$ @ Akash Patalwanshi Since $A\cap B=\varnothing$, $A\subset B^c$. Since $X=A\cup B$ then taking complement to both sides and using De Morgans Law, we get $A^c\cap B^c=\varnothing$. This implies that $B^c\subset A$. Equality follows. $\endgroup$ Sep 9, 2019 at 13:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .