The first remnants recorded on this site date to the Chalcolithic period approximately 3000 BCE, and were the basis for the early Roman settlement that developed. This ended with the sack of Carrazeda de Ansiães by northern barbarians in 409.
This was followed by the conquest of the region by Muslim forces in 711. The settlement escaped attacks by the Leonese forces during the 11th century, but, its position near Christian kingdoms meant that a fortification was required to protect their settlement. Yet, by 1057, the first Christian Foral Charter was instituted by the Ferdinand I of León and Castile, insinuating the fall of the Moorish fortress; the foral constituted one of the oldest geographic forals, defining the extent of Portuguese borders. During the High Middle Ages, the location already possessed a long cultural heritage, a factor that allowed it to become a fulcrum along the Douro River. Consequently, in subsequent centuries, the region experienced an exponential growth within the walled settlement.
In 1160, the first King of Portugal Afonso Henriques conferred the first Portuguese Foral charter, later re-confirmed and validated on 6 April 1198, by his successor King Sancho I, and again in April 1219, by King Afonso II. The village progressively imposed its importance in the territory it belonged, which included diverse resources, a proliferation of small agglomerations and agricultural parcels. It was in this context that in 1277, King Afonso III issued a charter to allow a fair in Ansiães.
King Ferdinand gave the town of Carrazeda de Ansiães to João Rodrigo Porto Carrero, in 1372. But, João Rodrigues took up arms for the Kingdom of León and Castile, which would only be settled in the Treaty of Badajoz in 1382.