Discovering Fossils states that the conditions necessary for fossil formation include rapid burial, ample sediment accumulation and eventual bedrock uplift. Time is also an important factor because fossils develop over millions of years. According to UK Fossils, most fossil discoveries occur at beaches, mines and quarries.
Rapid burial is essential for fossil formation because it prevents excessive decomposition. Dead animals that do not receive rapid burial decompose quickly, leaving nothing behind capable of fossilization.
After burial sediment accumulation presses the potential fossil deeper into the Earth's crust. During this process, the increasing pressure of the sediment layers squeezes all the remaining moisture out of the fossil. Minerals gradually infiltrate the pathways left by the escaping water. This phenomena is called perimineralization. Live Science states that this process is often called petrification, especially when referring to fossilized wood and other plant parts.
Millions of years of perimineralization create a precise copy of the fossil's former skeleton. The fossilized skeleton, however, is not subject to decay because it does not contain compounds that attract bacteria.
Completely perimineralized fossils are buried deep in the ground and must be brought close to the surface by geological uplift events such as earthquakes and volcanic activity. At this stage the fossils are ready for human discovery.