At least part of the variability in chronic pain symptoms and response to analgesics across individuals is thought to be genetically determined, but the genes involved are mostly unknown. The authors find that variations in the gene encoding the P2X7 receptor (P2X7R) that affect P2X7R pore formation alter mechanical allodynia following injury in mice and pain intensity ratings in human patients. A peptide that blocked pore formation in P2X7R also reduced pain behaviour in mice, suggesting that targeting P2X7R pore formation might reduce chronic pain in some individuals.