Seville was conquered by the Umayyad caliphate in 712. At that time the basilica was demolished to build the first military action. It seems to have been a tetrahedron casing and attached to the walls. During the period of the First Kingdoms in Taif, many constructions were implemented, such as stables and warehouses, which should not have changed the building as a whole. The castle began to gain importance in the first half of the twelfth century, during the Abbasid Dynasty, when the area doubled due to the construction of a large palace called Al Muwarak, under the present Patio de la Monteria, of which only some remains are preserved remains.