President of Peru Martín), and "Supreme Protector" (by Andrés de Santa Cruz). The following table contains a list of the individuals who have served as President of Peru. The Protectorate of Peru existed from August 3, 1821 until September 20, 1822. The Republic of Peru was declared on July 28, 1821 but it was constituted on September 20, 1822. It existed until August 11, 1836. In 1836, the south of the country declared itself independent by creating the Republic of South Peru, while the north of the country became the Republic of North Peru. The two states confederated with the Republic of Bolivia
First Upper Peru campaign authorities. The May Revolution, in Buenos Aires, was more successful, and ousted the viceroy Baltasar Hidalgo de Cisneros. The Primera Junta, which replaced him, prepared a military expedition to Upper Peru to secure the control of the area, while another expedition headed to Paraguay. Before proceeding to Upper Peru, this military campaign defeated a counter revolution in Córdoba, organized by the former viceroy Santiago de Liniers. Ortiz de Ocampo disobeyed orders to execute the prisoners, sending them to Buenos Aires instead. As a result, the Junta appointed Juan José Castelli as commander of the Army of the North instead of