How exactly did asexually reproducing organisms evolve into sexually reproducing ones? Why was it considered more favourable?
Sexual reproduction is a process where two cells fuse to form a diploid cell. Unicellular organisms (or even multicellular lower organisms like alga, fungi and protists) prefers to reproduce by asexual means under favourable conditions. But when the conditions become unfavourable, they opt to follow sexual reproduction. This suggests, sexual reproduction evolved to increase the chances of survival under unfavourable condition.
So how does sexual reproduction helps in increasing survival rate? By fusion of cells i.e., sexual reproduction a cell now becomes diploid and hence have two copies of its genome. This increased copy of genome is beneficial in repairing any breaks or alteration in genome, as the other copy will act as a template for repair (via homologous recombination).
To get a better hold of this, let us take an example. Let there be a population of haploid cells. This population was exposed to conditions which would cause damage to genome, specifically would cause breaks in DNA. There were two cells "Fella A" and "Fella B". They both knew that their genome has suffered damages, but neither was successful in repairing the DNA as they required an intact DNA template for repair. Suddenly "Fella B" came up with this great idea to fuse with "Fella A". This would work, reasoned "Fella B", as the position of damage in the DNA in his genome is different from the position in "Fella A". Fusion of cells was the first step towards evolution of sexual reproduction.
Later on the biological system realised importance of variation generated by sexual reproduction and hence this mode of reproduction caught on with various lineages.
Sexual vs asexual is not a binary condition it is a spectrum. Many organisms do both and/or a wide range of things in between. One of the most basic is plasmid swapping Bacterial conjunction in unicellular organisms.Even asexual selction has multiple forms of reproduction such as budding vs fission. Exchanging genes can be highly beneficial for multiple reasons including but not limited to; making infection far more difficult for parasites or giving a favorable gene a better change to spread since they are not stuck in the same genetic line forever.
Many organisms are opportunistically sexual, using sexual reproduction when they can (when they can find a mate or when resources are abundant) and using asexual selection when they cannot. this implies that there is an advantage to sexual selection even if what it is is debated, but it also shows it is an an either/or question the two forms of reproduction coexist quite well.
As for why sexual selection evolved, this is a hotly debated topic with no clear answer, it might be as simple as a way to get the benefits of gene exchange without the virus vulnerability plasmids create. It also a vague question by its very nature, because many organism engage in many different forms and combinations of forms of reproduction AND becasue many of these appear to have evolved independently the question is horribly muddled.
In short we know sexual reproduction has benefits but we can not say which ones were the deciding factors in its early evolution partially becasue there are several different instances of it evolving..
No, you've got the wrong end of the stick... asexual reproduction came from sexual reproduction, not the other way around! Asexual reproduction is a degenerate state that has benefits but is an evolutionary dead end because sexual combination is necessary to promote beneficial alleles and build new genes. See: https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4231362/
The answer that says "Sexual vs asexual is not a binary condition" is misleading; yes, that is true. Sexual species will start to experiment with asexual forms if they can because that confers advantages. The ability to be parthenogenic is very useful, but since it is a dead end, the ability to reproduce sexually should not be lost.
Although sex was quite tricky to evolve in the first place, it was necessary from the very beginning. It evolved from simpler systems of gene swapping and building that were needed from the beginning.