Gwrtheyrnion or Gwerthrynion was a commote in medieval Wales, located in Mid Wales on the north side of the River Wye; its historical centre was Rhayader. It is said to have taken its name from the legendary king Vortigern (Welsh: Gwrtheyrn). For most of the medieval era, it was associated with the cantref of Buellt and then Elfael, small regional kingdoms whose rulers operated independently of other powers. In the Norman era, like the rest of the region between Wye and Severn it came to be dominated by Marcher Lordships.