A group of agents must defend their individual income from an external threat by pooling their efforts against it. The winner of this confrontation is determined by a contest success function where members’ efforts display a varying degree of complementarity. Individual effort is costly and its cost follows a convex isoelastic function. We investigate how the success of the group in the conflict and its members’ utilities vary with the degree of within-group inequality. We show that there is a natural relationship between the group’s probability of victory and the Atkinson index of inequality. If members’ efforts are complementary or the cost function convex enough, more egalitarianism within the group increases the likelihood of victory against the external threat. The opposite holds when members’ efforts are substitutes and the cost linear enough.