Let $n > m$ be positive integers. Let $h:\mathbb{R}^n \to \mathbb{R}^m$ be a smooth map. Let $u \in \mathbb{R}^m$ be a regular value of $h$. Let $\epsilon \in \mathbb{R}^m$. We assume that $h^{-1}(u)$ and $h^{-1}(u+\epsilon)$ are compact.
I wonder if $\epsilon \neq 0$ and sufficiently small then $h^{-1}(u)$ and $h^{-1}(u+\epsilon)$ have the same number of connected components?
If $u$ is in the interior of the set of regular values (eg if $h$ is closed or – I think – if we replace $\mathbb{R}^n$ with a compact Riemannian manifold), yes. Indeed, assume that $B(u,2|\epsilon|)$ contains only regular values for $h$.
Let $\chi:\mathbb{R}^m \rightarrow [0,\infty)$ be a smooth compactly supported function, such that $\chi(B(u,|\epsilon|))=1$, and $\chi$ is zero outside a compact open subset of $B(u,2|\epsilon|)$.
Define, for each $x \in \mathbb{R}^n$ such that $h’(x)$ is onto, $L_x=h’(x)^T \circ (h’(x) \circ h’(x)^T)^{-1}$ a Moore-Penrose inverse, and $x \longmapsto L_x$ is smooth, $h’(x)L_x=\mathrm{id}_{\mathbb{R}^m}$. Consider now the following smooth vector field $X$ on $\mathbb{R}^n$: $X(x)=\chi(h(x))L_x(\epsilon)$.
One can check that under its flow $\phi^t$, if $1 \geq t \geq 0$ and $h(x)=u$, $h(\phi^t(x))=u+t\epsilon$; if $0 \geq t \geq -1$, $h(x)=u+\epsilon$, $h(\phi^t(x))=u+(1+t)\epsilon$.
Thus $\phi^1$ is a diffeomorphism between $h^{-1}(u)$ and $h^{-1}(u+\epsilon)$. QED