The anharmonic lattice is a representative example of an interacting bosonic many-body system. The self-consistent harmonic approximation has proven versatile for the study of the equilibrium properties of anharmonic lattices. However, the study of dynamical properties therewithin resorts to an ansatz, whose validity has not yet been theoretically proven. Here, we apply the time-dependent variational principle, a recently emerging useful tool for studying the dynamic properties of interacting many-body systems, to the anharmonic lattice Hamiltonian at finite temperature using the Gaussian states as the variational manifold. We derive an analytic formula for the position-position correlation function and the phonon self-energy, proving the dynamical ansatz of the self-consistent harmonic approximation. We establish a fruitful connection between time-dependent variational principle and the anharmonic lattice Hamiltonian, providing insights in both fields. Our work expands the range of applicability of time-dependent variational principle to first-principles lattice Hamiltonians and lays the groundwork for the study of dynamical properties of the anharmonic lattice using a fully variational framework.