Chickens like to sleep at the highest point available so you need to provide a roost for them. Hens and chickens like to perch when they sleep. This makes them feel secure and it keeps them out of harm's way since most predators are on the ground. The chickens sleep together on a roost for warmth and protection.
Do chickens sleep when they perch?
Roosting perches or roosting bars as they are also called are basically replicating a branch of a tree. So, just as a wild chicken would choose to sleep on, backyard chickens sleep on perches for the same effect. Having a perch is one of the essential features of a coop.
Should chicken perches be round or square?
Because chickens cling with their toes, the roost should be flat, but with slightly rounded corners front and back. So if you buy (for example) a standard piece of 2 x 2, make sure to round off the top edges. Make your perches 2 x 2, and long enough to fit your flock comfortably.