We report coherent coupling between two macroscopically separated nitrogen-vacancy electron spin ensembles in a cavity quantum electrodynamics system. The coherent interaction between the distant ensembles is directly detected in the cavity transmission spectrum by observing bright and dark collective multiensemble states and an increase of the coupling strength to the cavity mode. Additionally, in the dispersive limit we show transverse ensemble-ensemble coupling via virtual photons.