Thermoregulation
Palaeontologists are fairly certain that some fossil groups were endotherms. Obvious examples are pterosaurs, whose bodies were covered by hair (or hair-like filaments), and the smaller carnivorous dinosaurs which evolved feathers ("dinobirds"). It is thought that feathers originally functioned to keep body temperature higher. They appear on bird-like dinosaurs before there were any flying birds (Anchiornis huxlei), and they appear on dinosaurs which are too heavy to fly at all.