Agustin and his forces then marched on Mexico City and secured the recognition of Mexican independence from the last Spanish Viceroy Juan O'Donoju. General Iturbide had wanted Mexico to be independent but in personal union with King Fernando VII of Spain or upon his refusal under another Spanish Borbon prince who would come to be their monarch. However, Fernando VII refused to make any concessions on the subject of Mexico and along with that attitude no other European prince would dare to accept the crown. The Mexicans who gathered in the National Congress squabbled among themselves until the troops themselves hailed their commander as Agustin I, Emperor of Mexico. The Congress and Iturbide himself finally agreed and on July 21, 1822 he was crowned Emperor of Mexico in the National Cathedral.
Like many military leaders Emperor Agustin had not desired power, but if thrust upon him he expected to be obeyed, but this attitude was met with almost immediate and constant clashes with the divided and chaotic political scene in Mexico City, aided in no small part it must be said by the first U.S. ambassador to Mexico who was a Freemason and quickly spread membership in that secretive order amongst the upper echelons of liberal Mexico City society. One such recruit was an embittered former army officer named Antonio Lopez de Santa Anna who quickly began plotting against Iturbide whom he had previously sworn allegiance to. When the Congress became so difficult to deal with the Emperor said he would abdicate if that was the wish of the people. The Congress, without taking a vote or holding a referendum, said that it was and Iturbide abdicated and in May of 1823 went into exile in Europe, first in Italy and later England.
Almost as soon as he left leading conservatives appealed for him to return, arguing that the people were loyal, that he was needed to combat a threatened Spanish attempt at reconquest and that he would be greeted as a liberator from the political turmoil that followed his departure. Iturbide wrote the government, offering his services as a soldier to defend the country, but was ignored. By the summer of the following year he was finally prevailed upon to return to Mexico but his arrival was forewarned by the republican government who met him at the coast with troops. Despite being applauded by the populace he was quickly arrested by the local republican warlord and executed by firing squad on July 19, 1824. Ironically his political rehabilition later came about during the rule of the dictator Santa Anna who had first led the move to depose him. His remains are now entombed in the National Cathedral of Mexico in Mexico City.