structural:expansion, quality:correction
Classification and species

Like the spikes and shields of ankylosaurs, the bony plates and spines of stegosaurians evolved from the low-keeled osteoderms characteristic of basal thyreophorans. Galton (2019) interpreted plates of an armored dinosaur from the Lower Jurassic (Sinemurian - Pliensbachian) Lower Kota Formation of India as fossils of a member of Ankylosauria; the author argued that this finding indicates a probable early Early Jurassic origin for both Ankylosauria and its sister group Stegosauria.

The vast majority of stegosaurian dinosaurs thus far recovered belong to the Stegosauridae, which lived in the later part of the Jurassic and early Cretaceous, and which were defined by Paul Sereno as all stegosaurians more closely related to Stegosaurus than to Huayangosaurus. This group is widespread, with members across the Northern Hemisphere, Africa and possibly South America. Stegosaurus frequently is discovered in a clade within the Stegosauridae called Stegosaurinae, usually including the taxa Wuerhosaurus and Hesperosaurus. The cladogram below displays the results of the "preferred tree" phylogenetic analysis of Raven et al. (2023), showing the position of the Stegosaurinae within Stegosauria and Eurypoda.

In 2017, Raven and Maidment published a phylogenetic analysis including almost every known stegosaurian genus. Their dataset was expanded upon in the following years with additional taxa. In their 2024 description of stegosaur fossil material from China's Hekou Group, Li et al. used a modified version of the dataset of Raven and Maidment to analyze the phylogenetic relations of the Stegosauria: