Let $({\mathcal{M}},d,\mu)$ be the metric measure space with a Dirichlet form $\mathscr{E}$. In this paper, we obtain that the Campanato function and the Lipschitz function do always coincide. Our approach is based on the harmonic extension technology, which extends a function u on ${\mathcal{M}}$ to its Poisson integral Ptu on ${\mathcal{M}}\times\mathbb{R}_+$. With this tool in hand, we can utilize the same Carleson measure condition of the Poisson integral to characterize its Campanato/Lipschitz trace, and hence, they are equivalent to each other. This equivalence was previously obtained by Macías–Segovia [Adv. Math., 1979]. However, we provide a new proof, via the boundary value problem for the elliptic equation. This result indicates the famous saying of Stein–Weiss at the beginning of Chapter II in their book [Princeton Mathematical Series, No. 32, 1971].