[step:Prove $\partial f(x)$ is nonempty by separating the epigraph]
Define the epigraph of $f$ over $U$ by
\begin{align*}
\operatorname{epi}(f) := \{(y, t) \in U \times \mathbb{R} : t \ge f(y)\} \subseteq \mathbb{R}^{n+1}.
\end{align*}
We treat $\operatorname{epi}(f)$ as a subset of $\mathbb{R}^{n+1}$ equipped with its standard inner product.
[claim:$\operatorname{epi}(f)$ is convex.]
[/claim]
*Proof of claim.* Let $(y_1, t_1), (y_2, t_2) \in \operatorname{epi}(f)$ and $\lambda \in [0, 1]$. Then $y_1, y_2 \in U$ and $t_i \ge f(y_i)$ for $i = 1, 2$. By convexity of $U$, $\lambda y_1 + (1 - \lambda) y_2 \in U$. By convexity of $f$,
\begin{align*}
f(\lambda y_1 + (1 - \lambda) y_2) &\le \lambda f(y_1) + (1 - \lambda) f(y_2) \\
&\le \lambda t_1 + (1 - \lambda) t_2.
\end{align*}
Hence $(\lambda y_1 + (1 - \lambda) y_2, \lambda t_1 + (1 - \lambda) t_2) \in \operatorname{epi}(f)$. $\square$
Fix $x \in U$. The point $(x, f(x))$ belongs to $\operatorname{epi}(f)$ but not to its relative interior with respect to the vertical direction: any point $(x, f(x) - \varepsilon)$ with $\varepsilon > 0$ fails $t \ge f(x)$. Therefore $(x, f(x))$ is a boundary point of $\operatorname{epi}(f)$ in $\mathbb{R}^{n+1}$.
By the supporting hyperplane theorem applied to the convex set $\operatorname{epi}(f) \subseteq \mathbb{R}^{n+1}$ at the boundary point $(x, f(x))$, there exists a nonzero vector $(a, b) \in \mathbb{R}^n \times \mathbb{R}$ such that
\begin{align*}
a \cdot (y - x) + b (t - f(x)) \le 0 \qquad \text{for every } (y, t) \in \operatorname{epi}(f).
\end{align*}
Taking $y = x$ and $t = f(x) + s$ with $s > 0$ gives $b s \le 0$ for every $s > 0$, so $b \le 0$.
We claim $b < 0$. Suppose for contradiction $b = 0$. Then $a \cdot (y - x) \le 0$ for every $y \in U$. Since $x \in U$ and $U$ is open, $x + \delta a \in U$ for some $\delta > 0$, giving $\delta |a|^2 \le 0$, hence $a = 0$. This contradicts $(a, b) \ne 0$. Hence $b < 0$.
Set $p := -a / b \in \mathbb{R}^n$. For $y \in U$, taking $t = f(y) \ge f(y)$ in the inequality:
\begin{align*}
a \cdot (y - x) + b (f(y) - f(x)) \le 0.
\end{align*}
Dividing by $-b > 0$ and rearranging,
\begin{align*}
f(y) - f(x) \ge -\frac{a}{b} \cdot (y - x) = p \cdot (y - x).
\end{align*}
Hence $p \in \partial f(x)$, so $\partial f(x) \ne \varnothing$.
[/step]