That is one of the big questions in evolutionary biology. Sexual reproduction is a high-energy endeavor, requiring, often, the quest for a mate, the actual act of sex, and the carrying of offspring almost always by the females. Why not reproduce asexually? Many organisms do, though most of them are single-celled bacteria and other simple life forms. Still, some multicellular organisms also reproduce asexually, including many plants, insects, some reptiles, various mollusks and a few fishes. This highly efficient mode of reproduction is a low-energy endeavor, requiring no search for a mate, no sexual act, and sometimes, no carrying of offspring.
An advantage of sexual reproduction in a rapidly changing environment
The genetic diversity of sexual reproduction, observed in most eukaryotes, is thought to give species better chances of survival. Sexual reproduction was an early evolutionary innovation after the appearance of eukaryotic cells. During sexual reproduction, the genetic material of two individuals is combined to produce genetically-diverse offspring that differ from their parents. The fact that most eukaryotes reproduce sexually is evidence of its evolutionary success. In many animals, it is actually the only mode of reproduction. The genetic diversity of sexually-produced offspring is thought to give species a better chance of surviving in an unpredictable or changing environment.
When an environmental change imposes strong directional selection, there are two advantages of sexual reproduction. First, an asexual population is limited to the most extreme individual in the population, and progress under directional selection can go no farther without mutation; no such limitation applies to a sexual population. Second, more quantitatively, directional selection in an asexual population monotonically decreases the variance, whereas the variance of a sexual population quickly reaches a steady value; this difference remains even if the direction of selection occasionally changes. With realistic environmental changes small alterations in any particular measurement or trait are usually sufficient to keep up with the changes, but fitness, since it depends on a large number of traits, will be selected with greater intensity, which may be enough to confer a distinct advantage on sexual reproduction.