Moral judgments may be driven by both principled and opportunistic motivations. Being morally principled is to consistently adhere to a single set of rules about morality and justice. Opportunistic morality rather involves selectively enforcing rules when they are beneficial to one's interests. These two kinds of motivations sometimes pull in the same direction, other times not. Prior studies on moral motivations have mostly focused on principled morality. Opportunistic morality, along with its phenotypic and genetic correlates, remains largely unexamined. Here, utilizing a sample from the Norwegian Twin Registry, consisting of 312 monozygotic-and 298 dizygotic twin pairs (N = 1220), we measure people's propensity to react to injustice as victims, observers, beneficiaries, and perpetrators of injustice, using the Justice Sensitivity scale. Our genetically informative sample allows a biometric modeling approach that provides increased stringency in inferring latent psychological traits. We find evidence for two substantially heritable traits explaining correlations between Justice Sensitivity facets, which we interpret as a principled justice sensitivity (h 2 = .45) leading to increased sensitivity to injustices of all categories, and an opportunistic justice sensitivity (h 2 = .69) associated with increased victim sensitivity and a decreased propensity to feel guilt from being a perpetrator. These heritable justice traits share a genetic substrate with broad strategies for cooperation (as measured by altruism and trust) and for selectively benefitting oneself over the adaptive interests of others (as measured by social dominance orientation and support for monopolizing territory and resources), and differ genetically and phenotypically from Big Five personality traits.