Germinal centres are important sites for antibody diversification and affinity maturation, and are also a common origin of B cell malignancies. Despite being made up of motile cells, germinal centres are tightly confined within B cell follicles. The cues that promote this confinement are incompletely understood. P2RY8 is a Gα13-coupled receptor that mediates the inhibition of migration and regulates the growth of B cells in lymphoid tissues1,2. P2RY8 is frequently mutated in germinal-centre B cell-like diffuse large B cell lymphoma (GCB-DLBCL) and Burkitt lymphoma1,3-6, and the ligand for this receptor has not yet been identified. Here we perform a search for P2RY8 ligands and find P2RY8 bioactivity in bile and in culture supernatants of several mouse and human cell lines. Using a seven-step biochemical fractionation procedure and a drop-out mass spectrometry approach, we show that a previously undescribed biomolecule, S-geranylgeranyl-L-glutathione (GGG), is a potent P2RY8 ligand that is detectable in lymphoid tissues at the nanomolar level. GGG inhibited the chemokine-mediated migration of human germinal-centre B cells and T follicular helper cells, and antagonized the induction of phosphorylated AKT in germinal-centre B cells. We also found that the enzyme gamma-glutamyltransferase-5 (GGT5), which was highly expressed by follicular dendritic cells, metabolized GGG to a form that did not activate the receptor. Overexpression of GGT5 disrupted the ability of P2RY8 to promote B cell confinement to germinal centres, which indicates that GGT5 establishes a GGG gradient in lymphoid tissues. This work defines GGG as an intercellular signalling molecule that is involved in organizing and controlling germinal-centre responses. As the P2RY8 locus is modified in several other types of cancer in addition to GCB-DLBCL and Burkitt lymphoma, we speculate that GGG might have organizing and growth-regulatory roles in multiple human tissues.