Nest size, shape, and building materials vary greatly among birds. Nest placement and design, along with the behavior of the parents and young, combine to provide protection from temperature extremes and from predators. Birds instinctively know how to build the type of nest characteristic of its species. Woodpeckers excavate their nests in tree trunks or branches. These nest cavities offer safety from predators and a comfortable micro climate for the eggs and young.
Many female hornbills build their nests in tree cavities and are then sealed in by their mates.
Their mates feed them through a small hole, while they incubate the eggs and care for the chicks. Many tropical birds construct hanging nests, which help keep the occupants out of predator's reach and protect them from heavy rainfall. Some nests have a fake entrance that dead-ends to trick predatory snakes. The most frequent type of nest among North American songbirds, such as the robins, is a simple cup usually lined with fine grass or other soft material. Many colonial seabirds, such as Elegant Terns, make no nest, but simply lay their eggs in a shallow scrape in the sand or rocky ground.