The first dinosaurs evolved in the middle to late Triassic period, about 230 million years ago. Before then, the dominant land reptiles were archosaurs (“ruling lizards”) and therapsids (“mammal-like reptiles”), and for 20 million or so years after the first dinosaurs appeared the most fearsome reptiles were crocodiles.
It was only at the beginning of the Jurassic period, about 200 million years ago, that dinosaurs began their rise to dominance.