If $\mathcal{M}(X)$ is the space of all Borel probability measures on $X$ with Weak$^{∗}$ topology.

Is there an example where $\mathcal{M}(X)$ is compact, but $X$ is not metric or not compact?


Consider $X = \mathbb{N}$ with the "included-point topology at $0$". This topology is defined by declaring the non-empty open sets to be those containing $0$. Then $X$ is non-compact and is not Hausdorff, so is certainly not metrizable.

Since every non-empty open set in $X$ contains $0$, one can check that continuous real valued functions on $X$ are constant. In particular, the weak$^*$ topology on $\mathcal{M}(X)$ is the indiscrete topology [whose only non-empty open set is $\mathcal{M}(X)$] and hence $\mathcal{M}(X)$ is compact for the weak$^*$ topology since its only open cover is already finite.