The prefrontal cortex (PFC) is implicated in processing of the affective state of others through non-verbal communication. This social cognitive function is thought to rely on an intact cortical neuronal excitatory and inhibitory balance. Here combining in vivo electrophysiology with a behavioral task for affective state discrimination in mice, we show a differential activation of medial PFC (mPFC) neurons during social exploration that depends on the affective state of the conspecific. Optogenetic manipulations revealed a double dissociation between the role of interneurons in social cognition. Specifically, inhibition of mPFC somatostatin (SOM+), but not of parvalbumin (PV+) interneurons, abolishes affective state discrimination. Accordingly, synchronized activation of mPFC SOM+interneurons selectively induces social discrimination. As visualized by in vivo single-cell microendoscopic Ca2+ imaging, an increased synchronous activity of mPFC SOM+ interneurons, guiding inhibition of pyramidal neurons, is associated with affective state discrimination. Our findings provide new insights into the neurobiological mechanisms of affective state discrimination.