Afonso was born inCoimbra. As the second son of KingAfonso II of Portugal, he was not expected to inherit the throne, which was destined to go to his elder brotherSancho.[3]
In 1245,[5] conflicts between his brother, the king, and the church became unbearable.Pope Innocent IV ordered Sancho II to be removed from the throne and to be replaced by the Count of Boulogne. Afonso did not refuse the papal order and consequently marched to Portugal. Since Sancho was not a popular king the order was not hard to enforce, and he fled into exile to Toledo, Castile, where he died on 4 January 1248. Until his brother's death and his own eventual coronation, Afonso retained and used the title ofVisitador, Curador e Defensor do Reino (Overseer, Curator and Defender of the Kingdom).[6]
Determined not to make the same mistakes as his brother, Afonso III paid special attention to what the middle class, composed of merchants and small land owners, had to say. In 1254, in the city ofLeiria, he held the first session of theCortes, a general assembly comprising the nobility, the middle class and representatives of allmunicipalities. He also made laws intended to restrain the upper classes from abusing the least favored part of the population. Remembered as a notable administrator, Afonso III founded several towns, granted the title of city to many others and reorganized public administration.[8]
Afonso showed extraordinary vision for the time. Progressive measures taken during his kingship include: representatives of the commons, besides the nobility and clergy, were involved in governance; the end of preventive arrests such that henceforward all arrests had to be first presented to a judge to determine the detention measure; and fiscal innovation, such as negotiating extraordinary taxes with the mercantile classes and direct taxation of the Church, rather than debasement of the coinage. These may have led to his excommunication by the Holy See and possibly precipitated his death, and his sonDenis's premature rise to the throne at only 18 years old.[9]
Following his success against the Moors, Afonso III had to deal with a political situation concerning the country's borders with Castile. The neighbouring kingdom considered that the newly acquired lands of the Algarve should be Castilian, not Portuguese, which led to a series of wars between the two kingdoms. Finally, in 1267, theTreaty of Badajoz was signed inBadajoz, determining that the southern border between Castile and Portugal should be the RiverGuadiana, as it is today.[11]
* also an infante of Castile and León, Aragon, Sicily and Naples,§also an infante of Spain and an archduke of Austria,#also an infante of Spain,‡also an imperial prince of Brazil,¶also a prince of Saxe-Coburg and Gotha, Duke in Saxony,◙also a prince of Braganza,¤title removed in 1920 as their parents' marriage was deemed undynastic,ƒclaimant infante