If $\omega$ is harmonic, then it is $d$-closed. For the other direction, suppose $\omega$ is $d$-closed and primitive, i.e. $d\omega = 0$ and $\Lambda\omega = 0$. Then, by a Kähler identity, $$i\bar{\partial}^*\omega = [\Lambda, \partial] = \Lambda(\partial\omega) - d(\Lambda\omega) = \Lambda(\partial\omega)$$ and likewise $i\partial^*\omega = \Lambda(\bar{\partial}\omega)$. If $\omega$ is a $(p, q)$-form, then $d\omega = 0$ is equivalent to $\partial\omega = 0$ and $\bar{\partial}\omega = 0$, in which case it follows that $\partial^*\omega = 0$ and $\bar{\partial}^*\omega = 0$. Therefore $d^*\omega = 0$ and hence $\omega$ is harmonic. I'm not sure if the statement still holds if $\omega$ is an arbitrary form. The issue is that $d\omega = 0$ does not necessarily imply $\partial\omega = 0$ and $\bar{\partial}\omega = 0$ in this case.