We have recently described a mutualistic symbiosis in which Wolbachia bacteria were shown to improve the fitness of some Drosophila melanogaster stocks. Wolbachia did not extend longevity in all Drosophila genotypes, even though 16s rDNA sequences indicated that our Drosophila stocks were infected with the same Wolbachia strain. Here, we use reciprocal hybrid crosses between two Drosophila strains, one that lived longer with Wolbachia (Z53) and one that did not (Z2), to investigate the inheritance of the survival phenotype and its dependence on the host genotype, sex, and mating conditions. Wolbachia's positive effects were more apparent in hybrid flies than in parental flies, ruling out exclusive maternal inheritance or the dependence of the survival phenotype on Wolbachia strain differences. The Wolbachia survival effects were more apparent in single-sex cages, where courtship and mating were not permitted. In these cages, nearly all flies with Wolbachia lived longer than uninfected flies, even though strain Z2 showed no Wolbachia effect in mixed-sex mating cages. We used comparisons between single- and mixed-sex cages to estimate the cost of reproduction for both sexes. Our data suggest that Wolbachia infection may increase the inferred cost of reproduction, particularly in males. Wolbachia can even produce a positive survival effect almost as large as the negative survival effect associated with reproduction. We discuss the implications of our experiments for the study of insect symbioses.