Obviously, their structure and mode of operation means they have evolved from other living things, and the loss of normal structure occurs in many endoparasites. The origins of viruses in the evolutionary history of life are unclear: some may have evolved from plasmids – pieces of DNA that can move between cells – while others may have evolved from bacteria. In evolution, viruses are an important means of horizontal gene transfer, which increases genetic diversity.