  We consider the heat equation set on a bounded $C^1$ domain of $\mathbb R^n$
with Dirichlet boundary conditions. The first purpose of this paper is to prove
that the heat equation is observable from any measurable set $\omega$ with
positive $(n-1+\delta)$-Hausdorff content, for $\delta >0$ arbitrary small. The
proof relies on a new spectral estimate for linear combinations of Laplace
eigenfunctions, obtained via a Remez type inequality, and the use of the
so-called Lebeau-Robbiano's method. Even if this observability result is sharp
with respect to the scale of Hausdorff dimension, our second goal is to
construct families of sets $\omega$ which have codimension greater than or
equal to $1$ for which the heat equation remains observable.
