Mating strategies are to a large degree shaped by conflicts between the sexes, causing a rapid antagonistic coevolution of traits involved in reproduction. The view that sexual cannibalism represents a form of sexual conflict leads to the prediction of male traits that facilitate escape from cannibalistic females. A variety of traits have been suggested to serve this function in spiders, where sexual cannibalism is comparatively common. Empirical evidence, however, is virtually absent. Here we show experimentally that opportunistic mating with feeding females, which has been reported from several species of orb-weaving spiders, greatly reduces the risk of cannibalism and injury for males in the spider Nephila fenestrata. This has direct consequences for a male's fertilization success because surviving males can reduce the female's remating probability by guarding her against rivals. Although copulation with previously mated females sometimes appears to be mechanically impossible, second males that do copulate can expect to fertilize on average 64% of a female's eggs. Our results support the view that opportunistic mating may have evolved as a male tactic in a context of sexual conflict over sexual cannibalism.