Prieto was one of five sons of a Creole officer in Concepción. After finishing school, he joined the cavalry garrison in his home town. In 1810, he joined the Chilean fight for independence against his father's will. He met Manuela Warnes García de Zúñiga in Buenos Aires and married her in 1812. During the Chilean War of Independence, he served as a captain. In the dispute between Bernardo O'Higgins and José Miguel Carrera, he took the side of O'Higgins, who then made him Quartermaster general of the southern army.
After the defeat in the Battle of Rancagua, which he wasn't a part of, Prieto fled to Mendoza, Argentina to build up the Liberation Army of the Andes. After the victory of the Chileans in the battle of Chacabuco in 1817, in which he also wasn't involved, he was appointed Commanding General of Santiago, where he dealt with defense strategies and military matters. Then, he turned his attention to Peru, in order to support its fight for independence.
His military accomplishments - especially in the south of the country - earned the respect of conservative-centralist circles, which encouraged him to start a political career. He did so in 1823; in this year he was elected into the Chilean House of Deputies and appointed into State council. In this position, he advocated a strong and influential central government and fought the federalist independence ambitions of the regionalists. In 1828, he was elected vice-president of Chile.