They rarely grow deeper than 40m and they prefer salt water, doing poorly in areas where there is a lot of river runoff due to the freshwater as well as the silt which can cover a reef or muddy the water blocking the sunlight. The best temperature for coral reefs is between 25 and 31 C and the best salinity is between 34 and 37 parts per 1000. The appropriate temperatures and salinities are most often found in the tropics. Fringing reefs are platforms that are continuous with the shore. This occurs when a fringing reef grows upwards so that it can stay near the surface of the water.
Coral reefs like to grow just below the waterline so that they have the best access to the sunlight.
It is best if a reef grows at the same rate as the rise of the water. Barrier reefs also grow where the land is sinking faster than the water. The number of barrier reefs has increased dramatically as the greenhouse effect has warmed up our atmosphere causing the water levels to rise. Atolls are reefs surrounding a lagoon. They are created when an island surrounded by barrier reefs sinks below the ocean surface, leaving a circular reef, called an atoll.