We measured the effect of larval density on thorax length, development time, sex ratio and a measure of total fitness, using strains of Drosophila melanogaster artificially selected for increased thorax length, control lines otherwise cultured in an identical way, and the base stock from which the lines had been derived. We used the addition experimental design (Mather Br Caligari, 1981). No genotype-environment interaction was observed when comparing the reduction in thorax length of 'large' and 'control' lines with increasing larval density for any culture series, i.e. rank ordering of genotypes and additive genetic variances remained the same in all the environments tested. In contrast, the reduction in thorax length for the base stock as density increased was proportionally smaller than that of the 'large' and 'control' lines. Development time increased more rapidly with larval density in the 'large' lines than in the 'controls' or base stock. Sex ratio was unaffected by larval density but thorax length and the development time of females were more affected than those of males by increasing larval density. The estimate of total fitness showed clear evidence of gene-environment interaction for the effect of body size on fitness, with genetically large individuals at an increasing disadvantage with increasing larval density.