Banded iron formations are a specific type of sedimentary rock that formed many hundreds of millions of years ago in Earth's geological history. Sedimentary means that the rock formations consist of visible layers that formed one on top of each other over a long period of time. Iron means that the layers are composed of various iron containing chemicals, specifically iron oxides like magnetite and hematite. Since iron oxides are basically different forms of rust, this often gives banded iron formations a reddish color.
The formation of these rocks is not truly known. They do not seem to have formed in recent geological history, but they are often found in rock strata dating from around the time of the great oxygenation event when algae and cyanobacteria first appeared on the planet and began producing oxygen in enormous volumes, thus introducing oxygen gas into the atmosphere. It is surmised that since iron oxides are water insoluble, these banded iron formations formed at sea level as microorganisms produced oxygen that subsequently oxidized dissolved iron compounds in the water. These oxidized iron chemicals were insoluble and therefore precipitated onto the existing mud, thus producing the layering effect.