We study two rare decays, $Z to pi^+pi^-$ and $K^+K^-$, in the perturbative QCD approach up to the next-to-leading order of the strong coupling and the leading power of $1/m_Z$, $m_Z$ being the $Z$ boson mass. The branching ratios $mathcal{B}(Zto pi^+pi^-) = (0.83 pm 0.02 pm 0.02 pm 0.04)times 10^{-12}$ and $mathcal{B}(Zto K^+K^-) = (1.74^{+0.03}_{-0.05} pm 0.04 pm 0.02)times 10^{-12}$ are obtained and can be measured at a tera-$Z$ factory. Because the subleading-power contributions to the branching ratios are negligible, and the leading one does not depend on any free parameter, the two channels can serve as a touchstone for the applicability of the perturbative QCD approach.