Birds evolved from dinosaurs and both are descended from reptiles. The closest living reptilian relation of a bird is the crocodile.
https://reptiland.com/how-birds-and-reptiles-are-related/
"There are four major groups of reptiles living today: turtles/tortoises, lizards/snakes, crocodilians, and dinosaurs. The last two groups are archosaurs, a very specialized group of reptiles that have been around for 225 million years! Archosaurs are the living reptiles that birds are most closely related to."