There are a vast number of species of the unicellular organisms known as bacteria. They can inhabit any habitat on the planet from the soil to radioactive waste, for example, and make up much of the planet's biomass. Some of them can be pathogenic to other organisms, and some of them can offer some benefit to other organisms, or at least indulge in only benign interactions with them. But the majority of bacterial species are free living bacteria that are not tied to other organisms.
It is thought that bacteria are the first living things to exist on the planet. These early ancestors of our present-day bacteria, which are thought to have existed around 4 billion years ago. Stromatolites are an example of this. But these fossils lack the morphology needed to lay out a clear evolutionary account of the bacteria. Phylogeny is possible using the gene fragments that have been recovered from ancestral species.
Bacteria can exist in many different forms known as morphologies. But essentially, they are single-celled and around a couple micrometers in diameter, which is around ten times smaller than the more advanced eukaryotic cells that make up higher organisms. The genes of the bacterium cause different cell walls and cytoskeletons, which in turn lead to different shapes such as the spherical cocci and the rod-shaped baccilli, for example. It is these different shapes that determine the functions and behaviour available to the bacteria for things like attaching to other cells, taking in nutrients, and for motion.
The free living bacteria can exist in many different habitats such as appearing in fresh water in vast numbers, for example. There are vast numbers of bacteria found in the soil, for example. Here they are particularly important. They have a significant role to play in the fixation of nitrogen from the atmosphere, for example. Bacteria play a major part in a variety of the world's nutrient cycles.
But they can also live in many extreme environments as well. These bacteria, known as extremophiles, can live anywhere from radioactive waste to those that specialise in the hot deep ocean volcanic vents. The wide variety of properties that bacteria can have means that they can be used for tasks such as cleaning sewage treatment and for cleaning up chemical spillages, for example. They could also be used for generating useful chemicals that can be used for industrial and medical purposes.