Neighbour–stranger discrimination occurs when individuals respond with more aggression to strangers than to territorial neighbours—a phenomenon termed the “dear enemy phenomenon” (DEP). We investigated the DEP with male and female root voles (Microtus oeconomus Pallas 1776) using field dyadic arena tests conducted in enclosures where we could test for the effects of familiarity (familiar versus stranger), ownership (resident versus intruder status) and resource-holding potential (body mass) on territorial behaviours. The results showed that males put more effort into territorial defence than females, and males could discriminate between neighbours and strangers. In males, aggressiveness was influenced by a significant two-way interaction between treatment and ownership. Male residents were more aggressive towards stranger intruders than towards neighbour intruders, while male intruders were less aggressive towards stranger residents than towards neighbour residents. In females, neither treatment nor ownership status had a significant effect on aggressiveness. Familiar males performed more social behaviours but less non-social behaviours than stranger males. Furthermore, there was a clear dominance hierarchy between residents and intruders in stranger dyads, with the male territory holders dominating the intruder in pairwise interactions. To our knowledge, these results demonstrate for the first time DEP in a small mammal with a known pedigree and present the first evidence for “prior resident advantage” in voles. We argue that both ownership status and familiarity status affect how much an individual invests in territory defence. The benefits of neighbour–stranger discrimination for male root voles and the absence of neighbour–stranger discrimination in female root voles are discussed.