The coalescent process can describe the effects of selection at linked loci only if selection is so strong that genotype frequencies evolve deterministically. Here, we develop methods proposed by Kaplan, Darden, and Hudson to find the effects of weak selection. We show that the overall effect is given by an extension to Price's equation: the change in properties such as moments of coalescence times is equal to the covariance between those properties and the fitness of the sample of genes. The distribution of coalescence times differs substantially between allelic classes, even in the absence of selection. However, the average coalescence time between randomly chosen genes is insensitive to the current allele frequency and is affected significantly by purifying selection only if deleterious mutations are common and selection is strong (i.e., the product of population size and selection coefficient, Ns Ͼ 3). Balancing selection increases mean coalescence times, but the effect becomes large only when mutation rates between allelic classes are low and when selection is extremely strong. Our analysis supports previous simulations that show that selection has surprisingly little effect on genealogies. Moreover, small fluctuations in allele frequency due to random drift can greatly reduce any such effects. This will make it difficult to detect the action of selection from neutral variation alone. W E develop a diffusion approximation, first intro- (Maynard Smith and Haigh 1974;Kaplan et al. 1988;Barton 1998). However, the deterministic approximaduced by Kaplan et al. (1988), which extends the coalescent to take account of arbitrary forms of selection plainly fails when selection is weak or absent. Consider the relationships between genes that can be of two tion. Kingman (1982) introduced the coalescent process as a simple description of the genealogical relationallelic types. Even if these alleles are neutral, and so represent an arbitrary labeling of the genes, two genes ships among a set of neutral genes. Although the theory of the coalescent has developed largely independently, of the same allelic type are likely to be substantially more closely related than are two genes of different type. it is closely related to the classical concept of identity Moreover, the average relationship between randomly by descent (Nagylaki 1989). The coalescent extends chosen genes depends on the allele frequency, since an naturally to describe structured populations, in which allele that happens to have increased by chance will genes may be found in different places or embedded cause a selective sweep just as if it had increased by sein different genetic backgrounds. The effects of seleclection. Although relationships averaged over the distrition can easily be included, provided that it is so strong bution of allele frequencies and over allelic classes must relative to random drift that the frequencies of different be unaffected by the labeling of neutral alleles, relationgenetic backgrounds can be approximated as changing shi...