As a herd animal goats love to sleep in groups. It is important that the goats get enough rest to avoid illness. Goats also need a place to stay protected from predators during the night time. This is why goats usually like to sleep in barns or in dedicated goat houses.
During their night sleep goats prefer to be in an upright position with their hind legs tucked under and the front ones outstretched. This allows them to quickly stand up if they hear any danger. Domesticated goats tend to sleep with their mothers and babies as they feel safe this way. Baby goats often lay their heads on the mothers bodies as well. During REM (Rapid Eye Movement) sleep goats will keep their eyes closed. This is because they are looking for any potential threats.
Goats are very light sleepers and can wake up at the slightest sound. This is because they are a prey animal and always have to be on the lookout for predators. Goats are also prone to bloat so they have to be careful with their food. They eat hay and grass to help them digest their food better. During the day they graze and chew cud and often yawn after having a good sleep. It is also important to make sure the hay or grass is clean and not too wet for goats to be able to rest comfortably. If the goats have a run and use electric fence or other impenetrable fencing at night to prevent predators from getting them then they may not need to be kept in a confined area as much.